macropin / docker-strider

Strider-CD Docker Image
https://hub.docker.com/r/macropin/strider/
MIT License
13 stars 13 forks source link

SERVER_NAME parameter ignored #5

Closed tafkey closed 7 years ago

tafkey commented 8 years ago

The SERVER_NAME parameter is not passed as an environment variable when starting strider.

$ docker run -e SERVER_NAME http://xxx.xxx.xxx -d --link mongo --link smtp --name strider -p 80:3000 macropin/strider
macropin commented 8 years ago

@tafkey Sorry I only just saw this ticket now.

How can I test this issue?

macropin commented 8 years ago

Closing as I can't reproduce this issue.

emcniece commented 7 years ago

Hitting this as well. The container runs properly - I have it operational at https://ci.myproject.com and I have a separate Nginx container handling a proxy for port 3000 so the real URL is https://ci.myproject.com:3000. When I OAuth against Github the response URL is provided as:

http://localhost:3000/auth/github/callback?error=redirect_uri_mismatch&error_description=The+redirect_uri+MUST+match+the+registered+callback+URL+for+this+application.&error_uri=https%3A%2F%2Fdeveloper.github.com%2Fv3%2Foauth%2F%23redirect-uri-mismatch

This seems to indicate that the SERVER_NAME environment variable isn't being picked up on, even though after entering the container via bash and executing echo $SERVER_NAME does in fact return https://ci.myproject.com.

I'll keep digging for answers.

emcniece commented 7 years ago

I have confirmed that the environment variable is correctly set within the container. My issue was solved by following the install instructions from https://github.com/Strider-CD/strider-github, in particular setting PLUGIN_GITHUB_APP_ID and PLUGIN_GITHUB_APP_SECRET.

emcniece commented 7 years ago

I also had a typo in my SERVER_NAME variable - it was set to http://... instead of https://....

@macropin since you re-opened this issue after my discussion, I think it's safe to close it again.

macropin commented 7 years ago

Thanks for the update. Hopefully this saves someone else trouble.