Skip to content

Commit

Permalink
Fix docker
Browse files Browse the repository at this point in the history
  • Loading branch information
Fa8Bit committed Jun 3, 2024
1 parent 6ef85f5 commit 2633a4b
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 11 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,14 @@ file. If you changed the properties of the postgres db, you also have to change

### Run

#### Docker-compose
#### Run with Docker-compose

Start all dependencies with our docker-compose files.
Check
the [manual for starting the dependencies with docker-compose](https://github.com/Gamify-IT/docs/blob/main/dev-manuals/languages/docker/docker-compose.md)
.
Check the [manual for docker-compose](https://github.com/Gamify-IT/docs/blob/main/dev-manuals/languages/docker/docker-compose.md).

To run the main branch with minimal dependencies use the `docker-compose.yaml` file.\
To run the latest changes on any other branch than `main` use the `docker-compose-dev.yaml` file.


#### Project build

Expand Down
25 changes: 21 additions & 4 deletions docker-compose-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ services:
container_name: memory-db
image: postgres:14-alpine
restart: always
ports:
- "5432:5432"
expose:
- "5432"
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
Expand Down Expand Up @@ -81,18 +81,35 @@ services:
- KEYCLOAK_ISSUER=http://localhost/keycloak/realms/Gamify-IT
- KEYCLOAK_URL=http://keycloak/keycloak/realms/Gamify-IT

memory-backend:
container_name: memory-backend
image: ghcr.io/gamify-it/memory-backend:development
restart: always
pull_policy: always
expose:
- "80"
depends_on:
- memory-db
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POSTGRES_URL=postgresql://memory-db:5432/postgres
- OVERWORLD_URL=http://overworld-backend/api/v1
- KEYCLOAK_ISSUER=http://localhost/keycloak/realms/Gamify-IT
- KEYCLOAK_URL=http://keycloak/keycloak/realms/Gamify-IT

#frontends
landing-page:
container_name: landing-page
image: ghcr.io/gamify-it/landing-page:main
image: ghcr.io/gamify-it/landing-page:v1.6.0
restart: always
pull_policy: always
expose:
- "80"

overworld:
container_name: overworld
image: ghcr.io/gamify-it/overworld:main
image: ghcr.io/gamify-it/overworld:v1.5.0
restart: always
pull_policy: always
expose:
Expand Down
7 changes: 4 additions & 3 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,9 @@ services:

memory-backend:
container_name: memory-backend
build: .
image: ghcr.io/gamify-it/memory-backend:main
restart: always
pull_policy: always
expose:
- "80"
depends_on:
Expand All @@ -101,15 +102,15 @@ services:
#frontends
landing-page:
container_name: landing-page
image: ghcr.io/gamify-it/landing-page:main
image: ghcr.io/gamify-it/landing-page:v1.6.0
restart: always
pull_policy: always
expose:
- "80"

overworld:
container_name: overworld
image: ghcr.io/gamify-it/overworld:main
image: ghcr.io/gamify-it/overworld:v1.5.0
restart: always
pull_policy: always
expose:
Expand Down

0 comments on commit 2633a4b

Please sign in to comment.