Merge pull request #12 from cerc-io/dboreham/postgres-container-uid-fix

Override uid/gid of files created in the data dir
This commit is contained in:
David Boreham 2023-02-28 10:23:00 -07:00 committed by GitHub
commit 2291b2be8f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View File

@ -40,6 +40,9 @@ services:
- POSTGRES_USER=gitea
- POSTGRES_PASSWORD=gitea
- POSTGRES_DB=gitea
# Workaround below for lack of docker uid mapping. Change the container's postgres user's uid/gid to match the host user's
entrypoint: bash
command: -c 'usermod -u ${CERC_HOST_UID:-1000} postgres;groupmod -g ${CERC_HOST_GID:-1000} postgres;exec /usr/local/bin/docker-entrypoint.sh postgres'
networks:
- gitea
volumes:

View File

@ -4,4 +4,3 @@ if [[ -n "$CERC_SCRIPT_DEBUG" ]]; then
fi
mkdir -p ./gitea
mkdir -p ./gitea/ssh
mkdir -p ./postgres