Closed jdan closed 3 years ago
May be something to do with bash/sed? Or may be linux/windows thingy?
Experienced the same issue where DEFAULT_LANGUAGE
and HOST
are one the same line in the env.outline
file.
Ubuntu 20.04 Docker version 20.10.2, build 2291f61
Same. This is because the .env.sample
doesn't end with a newline.
These variables use env_add
- no sed
involed, just echo
.
cd /tmp
wget https://raw.githubusercontent.com/outline/outline/develop/.env.sample
echo "HOST" >> .env.sample
cat .env.sample
result:
# Custom logo that displays on the authentication screen, scaled to height: 60px
# TEAM_LOGO=https://example.com/images/logo.png
DEFAULT_LANGUAGE=en_USHOST
Simples fix is to just add an empty newline to https://raw.githubusercontent.com/outline/outline/develop/.env.sample
//edit: Sorry, the .env.sample
is from outline, not this repo.
Possible fix:
sed -i "\$a'${key}'='${val}'" $filename
instead of
echo "${key}=${val}" >> $filename
test:
wget https://raw.githubusercontent.com/outline/outline/develop/.env.sample
tail .env.sample
filename=".env.sample";key=FOO;val=BAR;sed -i "\$a'${key}'='${val}'" $filename
tail .env.sample
(thx to: https://stackoverflow.com/questions/10082204/add-a-newline-only-if-it-doesnt-exist)
Hi! Thanks for this - it let me try out outline in no time at all.
Wanted to file a lil bug for something a friend and I both caught independently. After going through
make install
I was receiving a 502 error. The logs mentioned something along the lines of: "Validation isIn on language failed." Curious, I poked around some of the env files and noticed the following at the bottom ofenv.outline
(No space after
en_US
, which seemed relevant to "isIn on language failed"). Adding a newline to change the text to:Fixed the issue on restart.