environment variable AUTOVACUUM added

The postgressql autovacuum feature is by default active. The environment variable AUTOVACUUM allows you to switch off this feature during start of docker container.
This commit is contained in:
Steffen Volkmann
2019-04-16 07:45:10 +02:00
parent ca32b809ea
commit a02daac961
4 changed files with 22 additions and 2 deletions

View File

@@ -5,6 +5,7 @@ FROM ubuntu:18.04
# Set up environment
ENV TZ=UTC
ENV AUTOVACUUM=on
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
# Install dependencies
@@ -135,9 +136,9 @@ RUN ln -sf /proc/1/fd/1 /var/log/apache2/access.log \
&& ln -sf /proc/1/fd/2 /var/log/apache2/error.log
# Configure PosgtreSQL
COPY postgresql.custom.conf /etc/postgresql/10/main/
COPY postgresql.custom.conf.tmpl /etc/postgresql/10/main/
RUN chown -R postgres:postgres /var/lib/postgresql \
&& chown postgres:postgres /etc/postgresql/10/main/postgresql.custom.conf \
&& chown postgres:postgres /etc/postgresql/10/main/postgresql.custom.conf.tmpl \
&& echo "\ninclude 'postgresql.custom.conf'" >> /etc/postgresql/10/main/postgresql.conf
# Start running