docker-compose.yml 434 B

12345678910111213141516171819202122232425262728
  1. version: '3.5'
  2. services:
  3. foo:
  4. image: alpine:3.10.1
  5. command: /bin/true
  6. deploy:
  7. replicas: 3
  8. restart_policy:
  9. condition: any
  10. max_attempts: 7
  11. resources:
  12. limits:
  13. memory: 300M
  14. cpus: '0.7'
  15. reservations:
  16. memory: 100M
  17. volumes:
  18. - foo:/bar
  19. networks:
  20. - bar
  21. volumes:
  22. foo:
  23. driver: default
  24. networks:
  25. bar:
  26. attachable: true