feat(podman_nginx): allow nginx to bind to additional ports

This commit is contained in:
Iain Learmonth 2025-12-22 11:07:06 +00:00
parent 0d9e5052ab
commit aa2fe2ddc6
2 changed files with 5 additions and 1 deletions

View file

@ -1,5 +1,6 @@
---
podman_nginx_additional_hostnames: []
podman_nginx_additional_publish_ports: []
podman_nginx_certbot_testing: false
# podman_nginx_frontend_network:
podman_nginx_podman_rootless_user: nginx

View file

@ -13,10 +13,13 @@ Image=docker.io/nginx:1
{% if podman_nginx_frontend_network is defined %}Network={{ podman_nginx_frontend_network }}.network{% endif +%}
PublishPort=80:80
PublishPort=443:443
{% for item in podman_nginx_additional_publish_ports %}
PublishPort={{ item }}
{% endfor %}
Volume=/home/{{ podman_nginx_podman_rootless_user }}/certbot/www:/var/www/certbot/:ro,z
Volume=/home/{{ podman_nginx_podman_rootless_user }}/certbot/conf/:/etc/letsencrypt/:ro,z
Volume=/home/{{ podman_nginx_podman_rootless_user }}/nginx:/etc/nginx/conf.d/:ro,z
{% for item in podman_nginx_additional_volumes %}
Volume={{ item.src }}:{{ item.dest }}:{{ item.options }}
{% endfor %}