Skip to content

Update MySQL environment variables in .env and docker-compose.yml #50

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .env
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,7 @@ DB_CLICKHOUSE_DB_NAME=cbioportal
DB_CLICKHOUSE_USERNAME=cbio_user
DB_CLICKHOUSE_PASSWORD=somepassword
DB_CLICKHOUSE_URL=jdbc:ch://cbioportal-clickhouse-database:8123/cbioportal
MYSQL_DATABASE=cbioportal
MYSQL_USER=cbio_user
MYSQL_PASSWORD=somepassword
MYSQL_ROOT_PASSWORD=somepassword
30 changes: 15 additions & 15 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version: '3'
version: "3"

services:
cbioportal:
Expand All @@ -11,13 +11,13 @@ services:
ports:
- "8080:8080"
volumes:
- ./study:/study/
- ${APPLICATION_PROPERTIES_PATH:-./config/application.properties}:/cbioportal-webapp/application.properties:ro
- ./study:/study/
- ${APPLICATION_PROPERTIES_PATH:-./config/application.properties}:/cbioportal-webapp/application.properties:ro
depends_on:
- cbioportal-database
- cbioportal-session
- cbioportal-database
- cbioportal-session
networks:
- cbio-net
- cbio-net
# TODO: servlet-api should be excluded from deps in mvn, the removal below is just a quick fix
# This might be helpful: https://stackoverflow.com/questions/36233626
command: /bin/sh -c "rm -rf /cbioportal-webapp/lib/servlet-api-2.5.jar && java -Xms2g -Xmx4g -cp '/cbioportal-webapp:/cbioportal-webapp/lib/*' org.cbioportal.PortalApplication --spring.config.location=cbioportal-webapp/application.properties --authenticate=false --session.service.url=http://cbioportal-session:5001/api/sessions/my_portal/ --clickhouse_mode=$${APP_CLICKHOUSE_MODE:-false} --spring.profiles.active=$${APP_SPRING_PROFILE:-default}"
Expand All @@ -26,16 +26,16 @@ services:
image: ${DOCKER_IMAGE_MYSQL}
container_name: cbioportal-database-container
environment:
MYSQL_DATABASE: cbioportal
MYSQL_USER: cbio_user
MYSQL_PASSWORD: somepassword
MYSQL_ROOT_PASSWORD: somepassword
MYSQL_DATABASE: ${MYSQL_DATABASE}
MYSQL_USER: ${MYSQL_USER}
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
volumes:
- ./data/cgds.sql:/docker-entrypoint-initdb.d/cgds.sql:ro
- ./data/seed.sql.gz:/docker-entrypoint-initdb.d/seed.sql.gz:ro
- cbioportal_mysql_data:/var/lib/mysql
- ./data/cgds.sql:/docker-entrypoint-initdb.d/cgds.sql:ro
- ./data/seed.sql.gz:/docker-entrypoint-initdb.d/seed.sql.gz:ro
- cbioportal_mysql_data:/var/lib/mysql
networks:
- cbio-net
- cbio-net
command: --local-infile=1
cbioportal-session:
restart: unless-stopped
Expand All @@ -61,7 +61,7 @@ services:

networks:
cbio-net:

volumes:
cbioportal_mysql_data:
cbioportal_mongo_data: