You've already forked RekomenciBackend
<type>(scope): <description>
i [body] [footer(s)]
This commit is contained in:
+3
-2
@@ -120,13 +120,14 @@ cache:
|
|||||||
stage: build
|
stage: build
|
||||||
script:
|
script:
|
||||||
- |
|
- |
|
||||||
buildah build . \
|
buildah bud \
|
||||||
--tag $IMAGE_NAME:$CI_COMMIT_SHA \
|
--tag $IMAGE_NAME:$CI_COMMIT_SHA \
|
||||||
--file $CONTAINERFILE \
|
--file $CONTAINERFILE \
|
||||||
--target $BUILDTARGET \
|
--target $BUILDTARGET \
|
||||||
--layers \
|
--layers \
|
||||||
--cache-from $IMAGE_NAME-cache \
|
--cache-from $IMAGE_NAME-cache \
|
||||||
--cache-to $IMAGE_NAME-cache
|
--cache-to $IMAGE_NAME-cache \
|
||||||
|
.
|
||||||
- buildah push $IMAGE_NAME:$CI_COMMIT_SHA
|
- buildah push $IMAGE_NAME:$CI_COMMIT_SHA
|
||||||
rules:
|
rules:
|
||||||
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
|
||||||
|
|||||||
+56
-47
@@ -22,12 +22,6 @@ services:
|
|||||||
restart: false
|
restart: false
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
required: true
|
required: true
|
||||||
configs:
|
|
||||||
- source: backend_config
|
|
||||||
target: /app/config.toml
|
|
||||||
secrets:
|
|
||||||
- source: firebase
|
|
||||||
target: /app/firebase.json
|
|
||||||
env_file:
|
env_file:
|
||||||
- path: ./infrastructure/configs/backend/.env.template
|
- path: ./infrastructure/configs/backend/.env.template
|
||||||
required: true
|
required: true
|
||||||
@@ -44,6 +38,19 @@ services:
|
|||||||
app_protocol: http
|
app_protocol: http
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
shm_size: 4mb
|
shm_size: 4mb
|
||||||
|
volumes:
|
||||||
|
- type: bind
|
||||||
|
source: ./infrastructure/configs/backend/config.toml
|
||||||
|
target: /app/config.toml
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
|
- type: bind
|
||||||
|
source: ./infrastructure/configs/backend/firebase.json
|
||||||
|
target: /app/firebase.json
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
|
|
||||||
tests:
|
tests:
|
||||||
build:
|
build:
|
||||||
@@ -70,11 +77,6 @@ services:
|
|||||||
restart: false
|
restart: false
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
required: true
|
required: true
|
||||||
configs:
|
|
||||||
- source: backend_config
|
|
||||||
target: /app/config.toml
|
|
||||||
- source: alembic_config
|
|
||||||
target: /app/alembic.ini
|
|
||||||
env_file:
|
env_file:
|
||||||
- path: ./infrastructure/configs/backend/.env.template
|
- path: ./infrastructure/configs/backend/.env.template
|
||||||
required: true
|
required: true
|
||||||
@@ -84,9 +86,20 @@ services:
|
|||||||
- default
|
- default
|
||||||
profiles:
|
profiles:
|
||||||
- tests
|
- tests
|
||||||
restart: no
|
|
||||||
shm_size: 4mb
|
shm_size: 4mb
|
||||||
volumes:
|
volumes:
|
||||||
|
- type: bind
|
||||||
|
source: ./infrastructure/configs/backend/config.toml
|
||||||
|
target: /app/config.toml
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
|
- type: bind
|
||||||
|
source: ./alembic.ini
|
||||||
|
target: /app/alembic.ini
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
- type: bind
|
- type: bind
|
||||||
source: ./.cov
|
source: ./.cov
|
||||||
target: /app/cov
|
target: /app/cov
|
||||||
@@ -104,11 +117,6 @@ services:
|
|||||||
restart: false
|
restart: false
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
required: true
|
required: true
|
||||||
configs:
|
|
||||||
- source: backend_config
|
|
||||||
target: /app/config.toml
|
|
||||||
- source: alembic_config
|
|
||||||
target: /app/alembic.ini
|
|
||||||
env_file:
|
env_file:
|
||||||
- path: ./infrastructure/configs/backend/.env.template
|
- path: ./infrastructure/configs/backend/.env.template
|
||||||
required: true
|
required: true
|
||||||
@@ -118,14 +126,23 @@ services:
|
|||||||
- default
|
- default
|
||||||
profiles:
|
profiles:
|
||||||
- migrations
|
- migrations
|
||||||
restart: no
|
|
||||||
shm_size: 4mb
|
shm_size: 4mb
|
||||||
|
volumes:
|
||||||
|
- type: bind
|
||||||
|
source: ./infrastructure/configs/backend/config.toml
|
||||||
|
target: /app/config.toml
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
|
- type: bind
|
||||||
|
source: ./alembic.ini
|
||||||
|
target: /app/alembic.ini
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
|
|
||||||
postgres:
|
postgres:
|
||||||
image: docker.io/postgres:17-alpine
|
image: docker.io/postgres:17-alpine
|
||||||
configs:
|
|
||||||
- source: postgres_config
|
|
||||||
target: /etc/postgresql/postgresql.conf
|
|
||||||
env_file:
|
env_file:
|
||||||
- path: ./infrastructure/configs/postgres/.env.template
|
- path: ./infrastructure/configs/postgres/.env.template
|
||||||
required: true
|
required: true
|
||||||
@@ -144,15 +161,18 @@ services:
|
|||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
shm_size: 128mb
|
shm_size: 128mb
|
||||||
volumes:
|
volumes:
|
||||||
|
- type: bind
|
||||||
|
source: ./infrastructure/configs/postgres/postgresql.conf
|
||||||
|
target: /etc/postgresql/postgresql.conf
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
- type: volume
|
- type: volume
|
||||||
source: postgres_data
|
source: postgres_data
|
||||||
target: /var/lib/postgresql/data
|
target: /var/lib/postgresql/data
|
||||||
|
|
||||||
pgadmin:
|
pgadmin:
|
||||||
image: docker.io/dpage/pgadmin4:9
|
image: docker.io/dpage/pgadmin4:9
|
||||||
configs:
|
|
||||||
- source: pgadmin_servers_config
|
|
||||||
target: /pgadmin4/servers.json
|
|
||||||
depends_on:
|
depends_on:
|
||||||
postgres:
|
postgres:
|
||||||
restart: false
|
restart: false
|
||||||
@@ -184,17 +204,19 @@ services:
|
|||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
shm_size: 4mb
|
shm_size: 4mb
|
||||||
volumes:
|
volumes:
|
||||||
|
- type: bind
|
||||||
|
source: ./infrastructure/configs/pgadmin/servers.json
|
||||||
|
target: /pgadmin4/servers.json
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
- type: volume
|
- type: volume
|
||||||
source: pgadmin_data
|
source: pgadmin_data
|
||||||
target: /var/lib/pgadmin
|
target: /var/lib/pgadmin
|
||||||
read_only: false
|
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
image: docker.io/redis:8-alpine
|
image: docker.io/redis:8-alpine
|
||||||
command: redis-server /usr/local/etc/redis/redis.conf
|
command: redis-server /usr/local/etc/redis/redis.conf
|
||||||
configs:
|
|
||||||
- source: redis_config
|
|
||||||
target: /usr/local/etc/redis/redis.conf
|
|
||||||
env_file:
|
env_file:
|
||||||
- path: ./infrastructure/configs/redis/.env.template
|
- path: ./infrastructure/configs/redis/.env.template
|
||||||
required: true
|
required: true
|
||||||
@@ -212,10 +234,15 @@ services:
|
|||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
shm_size: 4mb
|
shm_size: 4mb
|
||||||
volumes:
|
volumes:
|
||||||
|
- type: bind
|
||||||
|
source: ./infrastructure/configs/redis/redis.conf
|
||||||
|
target: /usr/local/etc/redis/redis.conf
|
||||||
|
read_only: true
|
||||||
|
bind:
|
||||||
|
selinux: Z
|
||||||
- type: volume
|
- type: volume
|
||||||
source: redis_data
|
source: redis_data
|
||||||
target: /data
|
target: /data
|
||||||
read_only: false
|
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
default:
|
default:
|
||||||
@@ -227,25 +254,7 @@ networks:
|
|||||||
internal: false
|
internal: false
|
||||||
external: false
|
external: false
|
||||||
|
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
postgres_data:
|
postgres_data:
|
||||||
pgadmin_data:
|
pgadmin_data:
|
||||||
redis_data:
|
redis_data:
|
||||||
|
|
||||||
|
|
||||||
configs:
|
|
||||||
backend_config:
|
|
||||||
file: ./infrastructure/configs/backend/config.toml
|
|
||||||
alembic_config:
|
|
||||||
file: alembic.ini
|
|
||||||
postgres_config:
|
|
||||||
file: ./infrastructure/configs/postgres/postgresql.conf
|
|
||||||
pgadmin_servers_config:
|
|
||||||
file: ./infrastructure/configs/pgadmin/servers.json
|
|
||||||
redis_config:
|
|
||||||
file: ./infrastructure/configs/redis/redis.conf
|
|
||||||
|
|
||||||
secrets:
|
|
||||||
firebase:
|
|
||||||
file: ./infrastructure/configs/backend/firebase.json
|
|
||||||
|
|||||||
Reference in New Issue
Block a user