Skip to content

Commit

Permalink
Merge pull request #12 from kamil-oberaj/KO/fix-docker-compose
Browse files Browse the repository at this point in the history
Ko/fix docker compose
  • Loading branch information
kamil-oberaj authored May 25, 2024
2 parents 90c8527 + e26f262 commit 8b1601b
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 33 deletions.
2 changes: 1 addition & 1 deletion StudioManager.API/Properties/launchSettings.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"dotnetRunMessages": true,
"launchBrowser": false,
"launchUrl": "swagger",
"applicationUrl": "https://localhost:5000;https://localhost:5001",
"applicationUrl": "https://localhost:5450;https://localhost:5451",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Local"
}
Expand Down
64 changes: 32 additions & 32 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: P@ssw0rd
POSTGRES_MULTIPLE_DATABASES: StudioManager,Keycloak
POSTGRES_MULTIPLE_DATABASES: StudioManager #,Keycloak
healthcheck:
test: 'pg_isready -U postgres --dbname=StudioManager'
interval: 10s
Expand All @@ -23,51 +23,51 @@

#### KEYCLOAK ####

studiomanager.keycloak:
image: quay.io/keycloak/keycloak:latest
container_name: studiomanager.keycloak
command: [ "start-dev", "--import-realm" ]
environment:
#KC_LOG_LEVEL: debug
KC_DB_VENDOR: postgres
KC_DB_ADDR: studiomanager.database
KC_DB_DATABASE: Keycloak
KC_DB_USER: postgres
KC_DB_PASSWORD: P@ssw0rd

KEYCLOAK_ADMIN: admin
KEYCLOAK_ADMIN_PASSWORD: admin
ports:
- 8080:8080
- 8443:8443
links:
- studiomanager.database
depends_on:
studiomanager.database:
condition: service_started
volumes:
- ./.containers/realm.json:/opt/keycloak/data/import/realm.json:r
restart: unless-stopped
# studiomanager.keycloak:
# image: quay.io/keycloak/keycloak:latest
# container_name: studiomanager.keycloak
# command: [ "start-dev", "--import-realm" ]
# environment:
# #KC_LOG_LEVEL: debug
# KC_DB_VENDOR: postgres
# KC_DB_ADDR: studiomanager.database
# KC_DB_DATABASE: Keycloak
# KC_DB_USER: postgres
# KC_DB_PASSWORD: P@ssw0rd
#
# KEYCLOAK_ADMIN: admin
# KEYCLOAK_ADMIN_PASSWORD: admin
# ports:
# - 8080:8080
# - 8443:8443
# links:
# - studiomanager.database
# depends_on:
# studiomanager.database:
# condition: service_started
# volumes:
# - ./.containers/realm.json:/opt/keycloak/data/import/realm.json:r
# restart: unless-stopped

#### API ####

studiomanager.api:
image: ${DOCKER_REGISTRY-}studiomanager.api
container_name: studiomanager.api
depends_on:
studiomanager.keycloak:
condition: service_started
# studiomanager.keycloak:
# condition: service_started
studiomanager.database:
condition: service_started
links:
- studiomanager.database
- studiomanager.keycloak
# - studiomanager.keycloak
build:
context: .
dockerfile: StudioManager.API/Dockerfile
ports:
- 5000:5000
- 5001:5001
- 5450:5450
- 5451:5451
environment:
- ASPNETCORE_URLS=http://+:5001
- ASPNETCORE_URLS=http://+:5451
restart: unless-stopped

0 comments on commit 8b1601b

Please sign in to comment.