template.yaml 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. ---
  2. kind: compose
  3. schema: "1.2"
  4. metadata:
  5. name: Nginx
  6. description: |-
  7. Nginx is a high-performance web server, reverse proxy, and load balancer known for its stability, rich feature set, simple configuration, and low resource
  8. consumption. It is widely used to serve static content, handle HTTP requests, and distribute traffic across multiple servers.
  9. ## Prerequisites
  10. * **Project:** https://nginx.org/
  11. * **Documentation:** https://nginx.org/en/docs/
  12. * **GitHub:** https://github.com/nginx/nginx
  13. version: 1.28.0-alpine
  14. author: Christian Lempa
  15. date: '2023-10-01'
  16. tags:
  17. - traefik
  18. - swarm
  19. spec:
  20. general:
  21. vars:
  22. service_name:
  23. default: "nginx"
  24. restart_policy:
  25. type: enum
  26. options: ["unless-stopped", "always", "on-failure", "no"]
  27. default: "unless-stopped"
  28. container_name:
  29. default: "nginx"
  30. container_timezone:
  31. default: "UTC"
  32. ports:
  33. vars:
  34. ports_http:
  35. description: HTTP port for nginx service
  36. type: int
  37. default: 8080
  38. ports_https:
  39. description: HTTPS port for nginx service
  40. type: int
  41. default: 8443
  42. traefik:
  43. vars:
  44. traefik_enabled:
  45. type: bool
  46. default: false
  47. traefik_network:
  48. default: "traefik"
  49. traefik_host:
  50. default: "nginx"
  51. traefik_domain:
  52. default: "home.arpa"
  53. traefik_entrypoint:
  54. default: "web"
  55. traefik_tls_entrypoint:
  56. default: "websecure"
  57. traefik_tls_enabled:
  58. type: bool
  59. default: true
  60. traefik_tls_certresolver:
  61. default: "cloudflare"
  62. network:
  63. vars:
  64. network_mode:
  65. type: enum
  66. options: ["bridge", "host", "macvlan"]
  67. default: "bridge"
  68. network_name:
  69. default: "bridge"
  70. swarm:
  71. vars:
  72. swarm_enabled:
  73. type: bool
  74. default: false
  75. swarm_replicas:
  76. description: Number of replicas for Swarm mode
  77. type: int
  78. default: 1