This repository has been archived by the owner on Jul 28, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
59 lines (52 loc) · 1.49 KB
/
docker-compose.yml
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
53
54
55
56
57
58
59
version: "3"
## to run this docker-compose.yml file, copy .env.dist to .env and fill in the values
# then run the following command:
# mvn -B package -DskipTests
# mkdir -p target/dependency && (cd target/dependency; jar -xf ../*.jar)
# docker-compose -f docker-compose.yml up -d --build
networks:
local:
driver: bridge
services:
app:
#image: lglot/sparql_endpoint_availability:v0.1
container_name: app
networks:
- local
build:
context: .
ports:
- "8080:8080"
depends_on:
- db
env_file:
- .env
restart: unless-stopped
environment:
- SPRING_SQL_INIT_PLATFORM=mysql
- SPRING_DATASOURCE_URL=jdbc:mysql://db:3306/sparql_endpoint_availability
- SPRING_DATASOURCE_USERNAME=${DATABASE_USERNAME}
- SPRING_DATASOURCE_PASSWORD=${DATABASE_PASSWORD}
- SPRING_JPA_HIBERNATE_DDL_AUTO=create-drop
- JWT_TOKEN_SECRET=${JWT_TOKEN_SECRET}
- APP_ADMIN_USERNAME=${APPLICATION_ADMIN_USERNAME}
- APP_ADMIN_PASSWORD=${APPLICATION_ADMIN_PASSWORD}
- SERVER_SERVLET_CONTEXT_PATH=/sparql
db:
image: mysql:latest
container_name: db
env_file:
- .env
networks:
- local
environment:
MYSQL_DATABASE: sparql_endpoint_availability
MYSQL_USER: ${DATABASE_USERNAME}
MYSQL_PASSWORD: ${DATABASE_PASSWORD}
MYSQL_ROOT_PASSWORD: ${DATABASE_PASSWORD}
volumes:
- db_volume:/var/lib/mysql
restart: unless-stopped
volumes:
db_volume:
external: false