-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
52 lines (52 loc) · 1.63 KB
/
Copy pathdocker-compose.yml
File metadata and controls
52 lines (52 loc) · 1.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
version: '3'
volumes:
mysql_data:
services:
db:
image: mysql:8.0.33
restart: always
environment:
MYSQL_ROOT_PASSWORD: change_this
MYSQL_DATABASE: ccapp
MYSQL_USER: admin
MYSQL_PASSWORD: change_this
ports:
- 127.0.0.1:3306:3306
volumes:
- mysql_data:/var/lib/mysql
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
interval: 5s
retries: 10
app:
depends_on:
db:
condition: service_healthy
build:
context: .
dockerfile: Dockerfile
volumes:
- ./data:/app/data
- ./migrations:/app/migrations
environment:
- PORT=5000
- STATIC_FOLDER=/app/assets
- SQLALCHEMY_DATABASE_URI=mysql+pymysql://admin:change_this@db/ccapp
- SECRET_KEY=change_this
- OIDC_ISSUER=https://keycloak_hostname/realms/realm_name
- OIDC_REDIRECT_URI=http://127.0.0.1:5000/redirect_uri
- CLIENT_ID=${CLIENT_ID}
- CLIENT_SECRET=${CLIENT_SECRET}
- MGP_USERNAME=${MGP_USERNAME}
- MGP_PASSWORD=${MGP_PASSWORD}
ports:
- 127.0.0.1:5000:5000
# to bootstrap the app, uncomment and execute each command in the given block of code one by one, running `docker-compose up` after each.
# Remember to re-comment the previously uncommented line before moving on to the next
#
# command: "flask db init"
# command: 'flask db migrate -m "add is_hidden field to image set"'
# command: 'flask db upgrade'
#
# if you need to change a model and add a migration, you will have to run 'flask db migrate -m "migration_message"', edit the migration file if necessary,
# then run 'flask db upgrade'