From 55fca68b06b571e842c5c316c1375caf4b0aa07a Mon Sep 17 00:00:00 2001 From: Orion Kindel Date: Wed, 19 Jul 2023 18:36:10 -0500 Subject: [PATCH] fix: gen-migrations workflow --- .gitea/workflows/gen-migrations.yml | 2 +- docker-compose.yml | 31 ++++++++++++----------------- 2 files changed, 14 insertions(+), 19 deletions(-) diff --git a/.gitea/workflows/gen-migrations.yml b/.gitea/workflows/gen-migrations.yml index da7e36a..f5f224a 100644 --- a/.gitea/workflows/gen-migrations.yml +++ b/.gitea/workflows/gen-migrations.yml @@ -39,5 +39,5 @@ jobs: git push fi env: - DOCKER_NETWORK_HOST: 'host.docker.internal' + DOCKER_NETWORK_HOST: 'localhost' DOCKER_HOST: 'unix:///run/user/1001/docker.sock' # HACK: rootless docker on gitea action runner diff --git a/docker-compose.yml b/docker-compose.yml index 325296a..e4a876c 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,21 +1,16 @@ -version: "3" -name: "dnim_db" +version: '3' +name: 'dnim_db' services: base: - container_name: "base" - image: "postgres:15.3-bullseye" - expose: ['5432'] - ports: - - "5432:5432" - env_file: - - "./.env.schema" + container_name: 'base' + network_mode: 'host' + image: 'postgres:15.3-bullseye' + env_file: ['./.env.schema'] + command: '-h localhost -p 5432' head: - container_name: "head" - image: "postgres:15.3-bullseye" - restart: "always" - expose: ['5433'] - ports: - - "5433:5433" - command: '-p 5433' - env_file: - - "./.env.schema" + container_name: 'head' + network_mode: 'host' + image: 'postgres:15.3-bullseye' + restart: 'always' + env_file: ['./.env.schema'] + command: '-h localhost -p 5433'