test_dockergen_v2.yml 589 B

1234567891011121314151617181920212223242526
  1. version: "2"
  2. services:
  3. nginx:
  4. image: nginx
  5. container_name: nginx
  6. volumes:
  7. - /etc/nginx/conf.d
  8. dockergen:
  9. image: nginxproxy/docker-gen
  10. command: -notify-sighup nginx -watch /etc/docker-gen/templates/nginx.tmpl /etc/nginx/conf.d/default.conf
  11. volumes_from:
  12. - nginx
  13. volumes:
  14. - /var/run/docker.sock:/tmp/docker.sock:ro
  15. - ../../nginx.tmpl:/etc/docker-gen/templates/nginx.tmpl
  16. web:
  17. image: web
  18. container_name: whoami
  19. expose:
  20. - "80"
  21. environment:
  22. WEB_PORTS: 80
  23. VIRTUAL_HOST: whoami.nginx.container.docker