diff --git a/Dockerfile b/Dockerfile index b79713f..2a44ca4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -44,7 +44,7 @@ RUN set -eux; \ echo 'en_US.UTF-8 UTF-8' >> /etc/locale.gen; \ locale-gen; \ locale -a | grep 'en_US.utf8' -ENV LANG en_US.utf8 +ENV LANG=en_US.utf8 RUN set -eux; \ apt-get update; \ @@ -110,25 +110,24 @@ RUN set -ex; \ find /usr -name '*.pyc' -type f -exec bash -c 'for pyc; do dpkg -S "$pyc" &> /dev/null || rm -vf "$pyc"; done' -- '{}' +; \ postgres --version -#RUN set -eux; \ -# savedAptMark="$(apt-mark showmanual)"; \ -# apt-get update; \ -# apt-get install -y --no-install-recommends ca-certificates wget libjson-c-dev libcurlpp-dev; \ -# apt-get build-dep -y "postgresql-$PG_MAJOR=$PG_VERSION"; \ -# rm -rf /var/lib/apt/lists/*; \ -# tempDir="$(mktemp -d)"; \ -# nproc="$(nproc)"; \ -# cp /usr/include/postgresql/15/server/pg_config.h /usr/include/postgresql/; \ -# cd "$tempDir"; \ -# wget https://github.com/EnterpriseDB/repmgr/releases/download/v5.5.0/repmgr-5.5.0.tar.gz; \ -# echo "c5633c351f3a0627a53ac1828ac7581ee74c7e0c repmgr-5.5.0.tar.gz" | sha1sum --check && \ -# tar -xvzf repmgr-5.5.0.tar.gz; \ -# cd repmgr; \ -# ./configure && make -j "$nproc" install; \ -# apt-mark auto '.*' > /dev/null; \ -# [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark > /dev/null; \ -# apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false - +RUN set -eux; \ + savedAptMark="$(apt-mark showmanual)"; \ + apt-get update; \ + apt-get install -y --no-install-recommends ca-certificates wget libjson-c-dev libcurlpp-dev; \ + apt-get build-dep -y "postgresql-$PG_MAJOR=$PG_VERSION"; \ + rm -rf /var/lib/apt/lists/*; \ + tempDir="$(mktemp -d)"; \ + nproc="$(nproc)"; \ + cp /usr/include/postgresql/15/server/pg_config.h /usr/include/postgresql/; \ + cd "$tempDir"; \ + wget https://github.com/EnterpriseDB/repmgr/releases/download/v5.5.0/repmgr-5.5.0.tar.gz; \ + echo "c5633c351f3a0627a53ac1828ac7581ee74c7e0c repmgr-5.5.0.tar.gz" | sha1sum --check && \ + tar -xvzf repmgr-5.5.0.tar.gz; \ + cd repmgr; \ + ./configure && make -j "$nproc" install; \ + apt-mark auto '.*' > /dev/null; \ + [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark > /dev/null; \ + apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false RUN set -eux; \ dpkg-divert --add --rename --divert "/usr/share/postgresql/postgresql.conf.sample.dpkg" "/usr/share/postgresql/$PG_MAJOR/postgresql.conf.sample"; \