mirror of
https://github.com/ChristianLight/tutor.git
synced 2024-12-12 06:07:56 +00:00
Fix Mongodb url in forum when running separate service
MONGOHQ_URL was not properly set when MONGODB_HOST/PORT was customised. That's because the environment variable was being defined in the Dockerfile, and not at runtime. Close #267
This commit is contained in:
parent
cac7e947b6
commit
475df37729
@ -4,6 +4,7 @@ Note: Breaking changes between versions are indicated by "💥".
|
||||
|
||||
## Unreleased
|
||||
|
||||
- [Bugfix] Fix MongoDb url in forum when running separate service (#267)
|
||||
- 💥[Improvement] Better `dev` commands, with dedicated development docker image. One of the consequences is that the `dev watchthemes` command is replaced by `dev run lms watchthemes`.
|
||||
- [Improvement] `images` commands now accept multiple `image` arguments
|
||||
|
||||
|
@ -46,6 +46,5 @@ ENV SEARCH_SERVER "http://elasticsearch:9200"
|
||||
ENV MONGODB_AUTH ""
|
||||
ENV MONGODB_HOST "mongodb"
|
||||
ENV MONGODB_PORT "27017"
|
||||
ENV MONGOHQ_URL "mongodb://$MONGODB_AUTH$MONGODB_HOST:$MONGODB_PORT/cs_comments_service"
|
||||
EXPOSE 4567
|
||||
CMD ./bin/unicorn -c config/unicorn_tcp.rb -I '.'
|
||||
|
@ -1,5 +1,7 @@
|
||||
#!/bin/sh -e
|
||||
|
||||
export MONGOHQ_URL="mongodb://$MONGODB_AUTH$MONGODB_HOST:$MONGODB_PORT/cs_comments_service"
|
||||
|
||||
echo "Waiting for mongodb/elasticsearch..."
|
||||
dockerize -wait tcp://$MONGODB_HOST:$MONGODB_PORT -wait $SEARCH_SERVER/content -wait-retry-interval 5s -timeout 600s
|
||||
|
||||
|
@ -1,2 +1,4 @@
|
||||
export MONGOHQ_URL="mongodb://$MONGODB_AUTH$MONGODB_HOST:$MONGODB_PORT/cs_comments_service"
|
||||
|
||||
bundle exec rake search:initialize
|
||||
bundle exec rake search:rebuild_index
|
||||
|
Loading…
Reference in New Issue
Block a user