DarthSim / overmind

Process manager for Procfile-based applications and tmux
MIT License
2.84k stars 79 forks source link

.overmind.env does not pass on existing defined variables #59

Closed davidkarlsen closed 4 years ago

davidkarlsen commented 4 years ago
~$ cat .overmind.env 

# Can't use backslash to make it readable
DEFAULT_JAVA_OPTIONS="-Dapp=${APP} -Djava.net.preferIPv4Stack=true -Dcom.sun.management.jmxremote.authenticate=false -Dlogback.ContextSelector=JNDI -Dcom.sun.management.jmxremote.ssl=false -Xlog:gc*:file=logs/gc.log::filecount=5,filesize=10M -XX:+HeapDumpOnOutOfMemoryError -Djetty.requestlog.timezone=Europe/Oslo -Ddefault.client.encoding=UTF-8 -server"
app@eos-jfr-srv-d1-fsjetty-7c7d8c8d6-dspfw:~$ echo $APP
eos-jfr-srv-d1-fsjetty-7c7d8c8d6-dspfw
app@eos-jfr-srv-d1-fsjetty-7c7d8c8d6-dspfw:~$ ps xa|grep app=
    26 pts/1    Sl+    1:24 java -Dapp= -Djava.net.preferIPv4Stack=true -Dcom.sun.management.jmxremote.authenticate=false -Dlogback.ContextSelector=JNDI -Dcom.sun.management.jmxremote.ssl=f
   154 ?        S+     0:00 grep --color=auto app=
app@eos-jfr-srv-d1-fsjetty-7c7d8c8d6-dspfw:~$ 

notice how -Dapp= w/o the variable passed

DarthSim commented 4 years ago

Hi,

Thanks for catching this. It's a bug in godotenv. I fixed it in my fork and temporary used it in master. I don't like the idea of releasing a new version until it's fixed in the main repo (there are PR https://github.com/joho/godotenv/pull/72 is merged for this), but it looks I'll have to.

You can install the fixed version of overmind with go get.

davidkarlsen commented 4 years ago

@DarthSim Hmm - that PR doesn't seem to have a lot of traction. Let's see what will happen - are there other alternative libraries which are better maintained?

davidkarlsen commented 4 years ago

@DarthSim any thoughts on alternatives?

davidkarlsen commented 4 years ago

@DarthSim This was fixed in latest release - wasn't it?

DarthSim commented 4 years ago

Yup. Sorry, I was tired as hell and didn't have a chance to mention the fix here. I decided to go with the forked version of godotenv.