···11-[[docker]]
22-[[postgresql]]
33-44-```fish
55-docker run --rm --name postgres \
66- -e POSTGRES_USER=$POSTGRES_USER \
77- -e POSTGRES_PASSWORD=$POSTGRES_PASSWORD \
88- -e POSTGRES_DB=$POSTGRES_DB \
99- -p 5432:5432 \
1010- -d postgres:latest
1111-```
1212-1313-## Optional flags
1414-1515-- `-d` Run the container in _detached_ mode
1616-- `-e` Is used to pass environment variables.
1717-- `-p` Maps the ports.
1818-- `--name` Sets the name of the running container.
1919-- `--rm` Deletes the container after it stops.
2020-2121-## Remember to include a password
2222-2323-> [!ERROR]
2424-> Database is uninitialized and superuser password is not specified.
2525-> You must specify POSTGRES_PASSWORD to a non-empty value for the
2626-> superuser. For example, "-e POSTGRES_PASSWORD=password" on "docker run".