I have a Rails app that I'm deploying using Docker containers. I'm using PostgreSQL for the database, and I'm trying to set up WAL-E to do continuous backups to an S3 bucket. The setup for this involves making a few changes to the postgresql.conf file.
I am using a postgres official image as a base image, and am passing in a postgresql.conf file. Here is my Dockerfile:
FROM postgres:9.4
MAINTAINER David Ham <me@example.com>
RUN apt-get update -y && apt-get install -y \
git \
python-virtualenv \
python-dev \
python-pip \
libevent-dev \
pv \
lzop
RUN virtualenv /opt/wale \
&& . /opt/wale/bin/activate \
&& pip install git+https://github.com/wal-e/wal-e
COPY postgresql.conf /postgresql-wal-e/postgresql-wal-e.conf
RUN chown -R postgres:postgres /postgresql-wal-e
CMD ["postgres", "-c", "config-file=/postgresql-wal-e/postgresql-wal-e.conf"]
Is this right? It seems to have copied in correctly, but is this the right way to configure Postgres with their official images?