run postgres db in docker code example
Example 1: connect to postgres database in docker container
$ docker exec -it postgres-container psql -U postgres
Example 2: docker run postgres locally
$ docker run -d --name my_postgres -v my_dbdata:/var/lib/postgresql/data -p 54320:5432 postgres:11