Created
July 11, 2017 15:22
-
-
Save allomov/1fd146ac559bd518d8e415dbe8359520 to your computer and use it in GitHub Desktop.
This file contains 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
version: '3.1' | |
services: | |
db: | |
image: postgres | |
environment: | |
POSTGRES_PASSWORD: example | |
dump-restorer: | |
image: postgres | |
command: | |
["psql", "-h", "db", "-U", "postgres", "-W", "example", "<", "/root/dumps/latest.yml"] | |
links: | |
- db | |
volumes: | |
- .:/root/dumps |
This file contains 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 --name test-postgres -e POSTGRES_PASSWORD=mysecretpassword -t -i postgres bash |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment