Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • c24025433/healthcare
1 result
Show changes
Commits on Source (2)
File moved
......@@ -4,10 +4,11 @@ services:
mariadb:
image: mariadb:10.11.11
container_name: mariadb
ports:
- "3306:3306"
# Host networking means this container listens on the host’s 3306
network_mode: "host"
environment:
MYSQL_ROOT_PASSWORD: comsc
MYSQL_DATABASE: healthcare
volumes:
- "./src/main/resources:/docker-entrypoint-initdb.d"
deploy:
......@@ -15,28 +16,23 @@ services:
limits:
cpus: '1'
memory: 1024M
networks:
- healthcare_network
healthcare_01:
build:
context: .
dockerfile: Docker/Dockerfile
container_name: healthcare_01
# Shares the host network, so no port mapping is needed
network_mode: "host"
environment:
- DB_URL=jdbc:mariadb://mariadb:3306/healthcare?createDatabaseIfNotExist=true
ports:
- "8080:8080"
- DB_URL=jdbc:mariadb://localhost:3306/healthcare?createDatabaseIfNotExist=true
- SPRING_DATASOURCE_URL=jdbc:mariadb://localhost:3306/healthcare?createDatabaseIfNotExist=true
- SPRING_DATASOURCE_USERNAME=root
- SPRING_DATASOURCE_PASSWORD=comsc
deploy:
resources:
limits:
cpus: '1'
memory: 1536M
networks:
- healthcare_network
depends_on:
- mariadb
networks:
healthcare_network:
name: healthcare_net
\ No newline at end of file