From 490f33c05ca6edb9c94540db6b2a8ce92bc64036 Mon Sep 17 00:00:00 2001 From: Sameer Naik Date: Sat, 5 Dec 2015 10:09:23 +0530 Subject: [PATCH] release 9.4-9 --- Changelog.md | 2 +- README.md | 38 +++++++++++++++++++------------------- VERSION | 2 +- docker-compose.yml | 2 +- 4 files changed, 22 insertions(+), 22 deletions(-) diff --git a/Changelog.md b/Changelog.md index d38d25e..558fab5 100644 --- a/Changelog.md +++ b/Changelog.md @@ -1,6 +1,6 @@ # Changelog -**latest** +**9.4-9** - complete rewrite - `PSQL_TRUST_LOCALNET` config parameter renamed to `PG_TRUST_LOCALNET` - `PSQL_MODE` config parameter renamed to `REPLICATION_MODE` diff --git a/README.md b/README.md index 97cc5f8..fc4cda4 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ [![Circle CI](https://circleci.com/gh/sameersbn/docker-postgresql.svg?style=shield)](https://circleci.com/gh/sameersbn/docker-postgresql) [![Docker Repository on Quay.io](https://quay.io/repository/sameersbn/postgresql/status "Docker Repository on Quay.io")](https://quay.io/repository/sameersbn/postgresql) [![](https://badge.imagelayers.io/sameersbn/postgresql.svg)](https://imagelayers.io/?images=sameersbn/postgresql:latest 'Get your own badge on imagelayers.io') -# sameersbn/postgresql:9.4-8 +# sameersbn/postgresql:9.4-9 - [Introduction](#introduction) - [Contributing](#contributing) @@ -60,7 +60,7 @@ Automated builds of the image are available on [Dockerhub](https://hub.docker.co > **Note**: Builds are also available on [Quay.io](https://quay.io/repository/sameersbn/postgresql) ```bash -docker pull sameersbn/postgresql:9.4-8 +docker pull sameersbn/postgresql:9.4-9 ``` Alternatively you can build the image yourself. @@ -77,7 +77,7 @@ Start PostgreSQL using: docker run --name postgresql -itd --restart always \ --publish 5432:5432 \ --volume /srv/docker/postgresql:/var/lib/postgresql \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` Login to the PostgreSQL server using: @@ -108,7 +108,7 @@ By default connections to the PostgreSQL server need to authenticated using a pa ```bash docker run --name postgresql -itd --restart always \ --env 'PG_TRUST_LOCALNET=true' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` > **Note** @@ -122,7 +122,7 @@ A new PostgreSQL database user can be created by specifying the `DB_USER` and `D ```bash docker run --name postgresql -itd --restart always \ --env 'DB_USER=dbuser' --env 'DB_PASS=dbuserpass' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` > **Notes** @@ -139,7 +139,7 @@ A new PostgreSQL database can be created by specifying the `DB_NAME` variable wh ```bash docker run --name postgresql -itd --restart always \ --env 'DB_NAME=dbname' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` Additionally, more than one database can be created by specifying a comma separated list of database names in `DB_NAME`. For example, the following command creates two new databases named `dbname1` and `dbname2`. @@ -149,7 +149,7 @@ Additionally, more than one database can be created by specifying a comma separa ```bash docker run --name postgresql -itd --restart always \ --env 'DB_NAME=dbname1,dbname2' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` # Enabling unaccent extension @@ -161,7 +161,7 @@ You can enable the unaccent extension on database(s) by specifying `DB_UNACCENT= ```bash docker run --name postgresql -itd \ --env 'DB_NAME=dbname' --env 'DB_UNACCENT=true' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` *By default the unaccent extension is disabled* @@ -174,7 +174,7 @@ If the `DB_USER` and `DB_PASS` variables are specified along with the `DB_NAME` docker run --name postgresql -itd --restart always \ --env 'DB_USER=dbuser' --env 'DB_PASS=dbuserpass' \ --env 'DB_NAME=dbname1,dbname2' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` In the above example `dbuser` with be granted access to both the `dbname1` and `dbname2` databases. @@ -186,7 +186,7 @@ Similar to the creation of a database user, a new PostgreSQL replication user ca ```bash docker run --name postgresql -itd --restart always \ --env 'REPLICATION_USER=repluser' --env 'REPLICATION_PASS=repluserpass' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` > **Notes** @@ -208,7 +208,7 @@ Begin by creating the master node of our cluster: docker run --name postgresql-master -itd --restart always \ --env 'DB_USER=dbuser' --env 'DB_PASS=dbuserpass' --env 'DB_NAME=dbname' \ --env 'REPLICATION_USER=repluser' --env 'REPLICATION_PASS=repluserpass' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` Notice that no additional arguments are specified while starting the master node of the cluster. @@ -223,7 +223,7 @@ docker run --name postgresql-slave01 -itd --restart always \ --env 'REPLICATION_MODE=slave' --env 'REPLICATION_SSLMODE=prefer' \ --env 'REPLICATION_HOST=master' --env 'REPLICATION_PORT=5432' \ --env 'REPLICATION_USER=repluser' --env 'REPLICATION_PASS=repluserpass' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` *In the above command, we used docker links so that we can address the master node using the `master` alias in `REPLICATION_HOST`.* @@ -255,7 +255,7 @@ docker run --name postgresql-snapshot -itd --restart always \ --env 'REPLICATION_MODE=snapshot' --env 'REPLICATION_SSLMODE=prefer' \ --env 'REPLICATION_HOST=master' --env 'REPLICATION_PORT=5432' \ --env 'REPLICATION_USER=repluser' --env 'REPLICATION_PASS=repluserpass' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` The difference between a slave and a snapshot is that a slave is read-only and updated whenever the master data is updated (streaming replication), while a snapshot is read-write and is not updated after the initial snapshot of the data from the master. @@ -277,7 +277,7 @@ docker run --name postgresql-backup -it --rm \ --env 'REPLICATION_HOST=master' --env 'REPLICATION_PORT=5432' \ --env 'REPLICATION_USER=repluser' --env 'REPLICATION_PASS=repluserpass' \ --volume /srv/docker/backups/postgresql.$(date +%Y%m%d%H$M%S):/var/lib/postgresql \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` Once the backup is generated, the container will exit and the backup of the master data will be available at `/srv/docker/backups/postgresql.XXXXXXXXXXXX/`. Restoring the backup involves starting a container with the data in `/srv/docker/backups/postgresql.XXXXXXXXXXXX`. @@ -288,7 +288,7 @@ You can customize the launch command of PostgreSQL server by specifying argument ```bash docker run --name postgresql -itd --restart always \ - sameersbn/postgresql:9.4-8 -c log_connections=on + sameersbn/postgresql:9.4-9 -c log_connections=on ``` Please refer to the documentation of [postgres](http://www.postgresql.org/docs/9.4/static/app-postgres.html) for the complete list of available options. @@ -299,7 +299,7 @@ By default the PostgreSQL server logs are sent to the standard output. Using the ```bash docker run --name postgresql -itd --restart always \ - sameersbn/postgresql:9.4-8 -c logging_collector=on + sameersbn/postgresql:9.4-9 -c logging_collector=on ``` To access the PostgreSQL logs you can use `docker exec`. For example: @@ -321,7 +321,7 @@ For example, if you want to assign the `postgres` user of the container the UID ```bash docker run --name postgresql -itd --restart always \ --env 'USERMAP_UID=999' --env 'USERMAP_GID=999' \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` # Maintenance @@ -333,7 +333,7 @@ To upgrade to newer releases: 1. Download the updated Docker image: ```bash - docker pull sameersbn/postgresql:9.4-8 + docker pull sameersbn/postgresql:9.4-9 ``` 2. Stop the currently running image: @@ -353,7 +353,7 @@ To upgrade to newer releases: ```bash docker run --name postgresql -itd \ [OPTIONS] \ - sameersbn/postgresql:9.4-8 + sameersbn/postgresql:9.4-9 ``` ## Shell Access diff --git a/VERSION b/VERSION index cda0649..20707ad 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -9.4-8 +9.4-9 diff --git a/docker-compose.yml b/docker-compose.yml index 9ac5f2a..c3488c4 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,6 +1,6 @@ PostgreSQL: restart: always - image: sameersbn/postgresql:9.4-8 + image: sameersbn/postgresql:9.4-9 ports: - "5432:5432" environment: