Hi, everyone
In order to run ./launcher rebuild app
, I use a proxy to help me pull code from Github smoothly.
env:
LANG: en_US.UTF-8
DISCOURSE_DEFAULT_LOCALE: zh_CN
HTTP_PROXY: http://10.27.xxx.xxx:7890
HTTPS_PROXY: http://10.27.xxx..xx:7890
But when I run my site, the Github login function is failed. I have to start my local proxy to fix it.
How can I remove the http_proxy and https_proxy of my running site.
Are there any commands as below I can follow to fix the problem?
./launcher enter app
//remove env
./launcher start app
Any helps would be appreciated.
Thanks.
1 Like
pfaffman
(Jay Pfaffman)
December 18, 2021, 9:52am
2
Maybe if you bootstrap
, then edit the app.yml
, then start
.
Also there is a command line option --docker-args
. There might be a way to pass something there when you bootstrap.
1 Like
Can I run ./launcher start app --docker-args
?
1 Like
pfaffman
(Jay Pfaffman)
December 18, 2021, 11:51am
4
Yes. You can. It’s a shell script and you can look at it. There is some documentation at the top of the file. But I pass docker args to launcher start to add stuff to get it to work with traefik.
1 Like
thanks, Jay, But I still can’t get rid of the effect caused by
./launcher rebuild app --docker-args="--net=host --env https_proxy=http://127.0.0.1:7890"
I need something to remove the proxy settings when I restart my app like this:
./launcher start app --docker-args="--net=host --removeEnv" //removeEnv is not a valid command, I only use this for illustration purpose
pfaffman
(Jay Pfaffman)
December 19, 2021, 9:05am
6
Have your tried changing the env settings in the yml file begotten /between the bootstrap and start?
Yes, but it doesn’t work, so I tried not to mess with the app.yml and use --docker-args to pass the GFW.
When I try to login with Github auth, it turns out that the request pass through the proxy address which is not what I expected.
BTW: my site is emacs-china.org , you can reproduce the issue with Github auth.
Thanks.
Finally, I got it working.
edit container/app.yml, remove http_proxy
./launcher destroy app
./launcher start app
./launcher destroy app could remove the docker env settings in most situation.
3 Likes
michaeld
(Michael - Communiteq)
December 26, 2021, 6:31am
9
Out of curiosity: What were you expecting? Isn’t that what HTTP_PROXY
is supposed to do?
1 Like