maxkoryukov / pgcli-docker

pgcli in a tiny Docker image powered by Alpine Linux

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

pgcli-docker

pgcli in a tiny Docker image powered by Alpine Linux

How to use this image

Print help:

docker run --rm diyan/pgcli --help

Run PostgreSQL server if you don't have it:

docker run -d --name=postgres \
  -p 5432:5432 \
  -e POSTGRES_PASSWORD=secret \
  postgres:9.5

Run pgcli:

docker run --rm -ti --name=pgcli \
  -e PGPASSWORD=secret \
  --link=postgres:postgres \
  diyan/pgcli \
  --host=postgres \
  --dbname=postgres \
  --user=postgres

If you want to preserve query-history, pgcli-log and pgcli-config on the host-machine, just mount the volume to the path /root/.config/pgcli/ for pgcli files:

docker run -v $(pwd)/pgcli-cfg:/root/.config/pgcli/ --rm diyan/pgcli --help

AUTHORS

LICENSE

MIT

About

pgcli in a tiny Docker image powered by Alpine Linux

License:MIT License


Languages

Language:Dockerfile 100.0%