Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use correct DB URI under docker-compose #210

Closed
wants to merge 1 commit into from
Closed

Use correct DB URI under docker-compose #210

wants to merge 1 commit into from

Conversation

rcowsill
Copy link
Contributor

Note: This PR is against feature/187 rather than master. The issue exists in both branches, but it only causes CI failures in feature/187. I feel that makes it a "nice to have" in master, but high priority in this branch.

Currently the three jobs in feature/187 CI builds all connect to the same mongolab URI. Only one job in each build can succeed; the others will fail the signup spec because the "new user" already exists in the database.

This change updates the docker-compose configuration to set the MONGODB_URI env var. That makes the web service connect to the mongo service (in the other container) rather than the default mongolab URI.

It also propagates NODE_ENV from the environment where docker-compose is run into the web container. That means the web service uses the appropriate config instead of always using development.

This should make the CI builds in this branch as reliable those in master. There's still one other issue that needs fixing to make it fully reliable, see #159 for further details.

When using docker-compose the web service should connect to the mongo service container, not mongolab.
Also import NODE_ENV into the web service container so the appropriate config is selected
@rcowsill
Copy link
Contributor Author

Looks like GitHub or Travis got confused and queued up two checks pointing to the same build. All three jobs passed, but one of the checks thinks they still queued.

@rcowsill
Copy link
Contributor Author

I'm closing this PR while I reorganise branches in my fork of the project. I'll make a new pull request with the changes once I'm done.

@rcowsill rcowsill closed this Sep 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant