Sign inSign up

mayeu/multipostgres

By mayeu

•Updated over 7 years ago

A docker Postgres image where you can add as many DB as you want via POSTGRES_ADDITIONAL_DB

Image
0

190

mayeu/multipostgres repository overview

⁠This project is archived, please take a look at mayeu/docker-postgres-dev⁠ instead.

⁠Multi Postgres

A postgres docker image where you can create multiple database.

This image is enterily based on the official postgres one⁠.

Thus I only document the additional variable I added.

⁠Environement variable

⁠POSTGRES_ADDITIONAL_DB

Beside the database created with POSTGRES_DB, this image provide support to have any number of DB via the POSTGRES_ADDITIONAL_DB.

Note that all the DB created like this will use the same user and password that you provided via POSTGRES_USER and POSTGRES_PASSWORD

Example of use in a docker-compose.yml file:

version: '3'
services:
  db:
    image: mayeu/multipostgres
    environment:
      POSTGRES_PASSWORD: password
      POSTGRES_USER: user
      POSTGRES_DB: db1
      POSTGRES_ADDITIONAL_DB: db2,db3,db4

You can put one or more databse. All database must be separated by a coma (',').

Tag summary

Content type

Image

Digest

Size

79.9 MB

Last updated

over 7 years ago

docker pull mayeu/multipostgres