Skip to content

Instantly share code, notes, and snippets.

@victorjtfranco
Created March 20, 2017 14:16
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save victorjtfranco/9e9371e835e1bb3def03a3d13044b572 to your computer and use it in GitHub Desktop.
Save victorjtfranco/9e9371e835e1bb3def03a3d13044b572 to your computer and use it in GitHub Desktop.
Extending Postgres Docker
#!/bin/bash
echo "include '/postgresql-extend.conf'" >> $PGDATA/postgresql.conf
FROM postgres:9.4
MAINTAINER Victor Franco "victorjtfranco@users.noreply.github.com"
COPY add-config.sh /docker-entrypoint-initdb.d/
COPY postgresql-extend.conf /
wal_level = 'logical'
max_worker_processes = 10 # one per database needed on provider node
# one per node needed on subscriber node
max_replication_slots = 10 # one per node needed on provider node
max_wal_senders = 10 # one per node needed on provider node
@victorjtfranco
Copy link
Author

@victorjtfranco
Copy link
Author

It is enough to add RUN echo -e "\n\ninclude '/postgresql-extend.conf'" >> /usr/share/postgresql/postgresql.conf.sample to Dockerfile thanks to docker-library/postgres#127

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment