test_hsts.yml 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. volumes:
  2. nginx_conf:
  3. services:
  4. web1:
  5. image: web
  6. expose:
  7. - "81"
  8. environment:
  9. WEB_PORTS: "81"
  10. VIRTUAL_HOST: "web1.nginx-proxy.tld"
  11. web2:
  12. image: web
  13. expose:
  14. - "81"
  15. environment:
  16. WEB_PORTS: "81"
  17. VIRTUAL_HOST: "web2.nginx-proxy.tld"
  18. HSTS: "off"
  19. web3:
  20. image: web
  21. expose:
  22. - "81"
  23. environment:
  24. WEB_PORTS: "81"
  25. VIRTUAL_HOST: "web3.nginx-proxy.tld"
  26. HSTS: "max-age=86400; includeSubDomains; preload"
  27. web4:
  28. image: web
  29. expose:
  30. - "81"
  31. environment:
  32. WEB_PORTS: "81"
  33. VIRTUAL_HOST: "web4.nginx-proxy.tld"
  34. HSTS: "off"
  35. HTTPS_METHOD: "noredirect"
  36. web5:
  37. image: web
  38. expose:
  39. - "81"
  40. environment:
  41. WEB_PORTS: "81"
  42. VIRTUAL_HOST: http3-vhost-enabled.nginx-proxy.tld
  43. labels:
  44. com.github.nginx-proxy.nginx-proxy.http3.enable: "true"
  45. sut:
  46. profiles:
  47. - singleContainer
  48. image: nginxproxy/nginx-proxy:test
  49. volumes:
  50. - &dockerSocket /var/run/docker.sock:/tmp/docker.sock:ro
  51. - &certs ./certs:/etc/nginx/certs:ro
  52. sut-dockergen:
  53. profiles:
  54. - separateContainers
  55. image: nginxproxy/nginx-proxy:test-dockergen
  56. volumes:
  57. - &confVolume nginx_conf:/etc/nginx/conf.d
  58. - *dockerSocket
  59. - *certs
  60. sut-nginx:
  61. profiles:
  62. - separateContainers
  63. container_name: nginx-proxy
  64. image: nginx:alpine
  65. volumes:
  66. - *confVolume
  67. - *certs
  68. labels:
  69. - "com.github.nginx-proxy.nginx-proxy.nginx"