Last active
January 13, 2026 19:03
-
-
Save gmdias727/c50d002bb8a3084f058a8f93b7c4bb1c to your computer and use it in GitHub Desktop.
here I learned docker run command
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| docker run -it --rm -e POSTGRES_PASSWORD=postgres -e POSTGRES_USER=postgres -e POSTGRES_DB=postgres -p 5432:5432 postgres:17.7-bookworm -d postgres | |
| # OR | |
| docker run -it --rm \ | |
| -e POSTGRES_PASSWORD=postgres \ | |
| -e POSTGRES_USER=postgres \ | |
| -e POSTGRES_DB=postgres \ | |
| -p 5432:5432 \ | |
| -d postgres \ | |
| postgres:17.7-bookworm | |
| # Are the same! | |
| # This container will vanish at the end of the process | |
| docker run -it --rm postgres:17.7-bookworm psql -h localhost -U postgres --port 5432 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment