diff options
author | Freya Murphy <freya@freyacat.org> | 2024-12-23 10:39:16 -0500 |
---|---|---|
committer | Freya Murphy <freya@freyacat.org> | 2024-12-23 10:39:16 -0500 |
commit | de9cae795f93d03e68d965c59af4b21d96df4ec7 (patch) | |
tree | ad4f903c04630b3b92e2b9b5d06d5b8647d299bb /build/postgres/Dockerfile | |
parent | license (diff) | |
download | crimson-de9cae795f93d03e68d965c59af4b21d96df4ec7.tar.gz crimson-de9cae795f93d03e68d965c59af4b21d96df4ec7.tar.bz2 crimson-de9cae795f93d03e68d965c59af4b21d96df4ec7.zip |
initial
Diffstat (limited to 'build/postgres/Dockerfile')
-rw-r--r-- | build/postgres/Dockerfile | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/build/postgres/Dockerfile b/build/postgres/Dockerfile new file mode 100644 index 0000000..8223800 --- /dev/null +++ b/build/postgres/Dockerfile @@ -0,0 +1,24 @@ +FROM postgres:16-alpine + +# install packages +RUN apk add --no-cache make git shadow +RUN rm -fr /var/cache/apk/* + +# install pgjwt +RUN git clone https://github.com/michelp/pgjwt.git /tmp/pgjwt +WORKDIR /tmp/pgjwt +RUN make install + +# update postgres user +RUN groupmod --gid 1000 postgres +RUN usermod --uid 1000 postgres + +# remove build packages +RUN apk del make git shadow + +# set perms +RUN chown -R postgres:postgres /var/run/postgresql + +# fix workdir +WORKDIR / +USER postgres |