Guest User

Untitled

a guest
Dec 26th, 2017
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. version: "2"
  2. services:
  3. server:
  4. build: ./path/to/server
  5. ports:
  6. - 3003:3003
  7. command: bash -c 'while !</dev/tcp/db/5432; do sleep 1; done; npm start'
  8. depends_on:
  9. - db
  10. environment:
  11. - PORT=3003
  12. volumes:
  13. - client:/client
  14. db:
  15. image: postgres
  16. environment:
  17. - POSTGRES_USER=postgres
  18. - POSTGRES_PASSWORD=password
  19. - POSTGRES_DB=example
  20. volumes:
  21. - data:/var/lib/postgresql/data
  22.  
  23. volumes:
  24. data: {}
  25. client: {}
Add Comment
Please, Sign In to add comment