Skip to content

Latest commit

 

History

History
19 lines (13 loc) · 985 Bytes

README.md

File metadata and controls

19 lines (13 loc) · 985 Bytes

PostgreSQL Docker Image

Docker image for Application database

This image runs PostgreSQL and creates app database and number of users:

  • postgres - DB root
  • app

To run it locally just use docker-compose:

$ docker-compose up

That's all, you can connect to the running DB using psql, DataGrip or any other tools.

Checking installation with psql

To use psql client, you need Postgres installed locally. Check out this guide for platform-dependent recommendations, but it should be as simple as an apt-get install postgresql on Linux, brew install postgres on OSX, or a binary download on Windows (make sure it is Postgres = 9.5).

Once properly installed, connecting to the DB server should be as simple as psql -h localhost -U app. Verify that things are OK with something like SELECT version(); command. \q to quit.