chore(nginx_fpm_proxy): add nextcloud_nginx_container_ports

This commit is contained in:
transcaffeine 2024-07-27 21:35:30 +02:00
parent 95aff397b8
commit 5ed71fa11a
Signed by: transcaffeine
GPG Key ID: 03624C433676E465
1 changed files with 6 additions and 5 deletions

View File

@ -1,13 +1,13 @@
--- ---
- name: Create directory for nginx config - name: Create directory for nginx config
file: ansible.builtin.file:
path: "{{ nextcloud_nginx_basepath }}" path: "{{ nextcloud_nginx_basepath }}"
state: directory state: directory
mode: 0750 mode: 0750
- name: Template nginx reverse proxy config for nextcloud - name: Template nginx reverse proxy config for nextcloud
template: ansible.builtin.template:
src: nextcloud-nginx.conf.j2 src: nextcloud-nginx.conf.j2
dest: "{{ nextcloud_nginx_config }}" dest: "{{ nextcloud_nginx_config }}"
vars: vars:
@ -18,19 +18,20 @@
notify: restart-nextcloud-nginx notify: restart-nextcloud-nginx
- name: Ensure nginx docker image is pulled - name: Ensure nginx docker image is pulled
docker_image: community.general.docker_image:
name: "{{ nextcloud_nginx_container_image_ref }}" name: "{{ nextcloud_nginx_container_image_ref }}"
state: present state: present
source: pull source: pull
force_source: "{{ nextcloud_nginx_container_image_force_pull }}" force_source: "{{ nextcloud_nginx_container_image_force_pull }}"
- name: Ensure nginx is running for FPM and static file serving - name: Ensure nginx is running for FPM and static file serving
docker_container: community.docker.docker_container:
env: "{{ nextcloud_nginx_container_env }}"
name: "{{ nextcloud_nginx_container_name }}" name: "{{ nextcloud_nginx_container_name }}"
image: "{{ nextcloud_nginx_container_image_ref }}" image: "{{ nextcloud_nginx_container_image_ref }}"
ports: "{{ nextcloud_nginx_container_ports }}"
volumes: "{{ nextcloud_nginx_container_volumes }}" volumes: "{{ nextcloud_nginx_container_volumes }}"
labels: "{{ nextcloud_nginx_container_labels }}" labels: "{{ nextcloud_nginx_container_labels }}"
env: "{{ nextcloud_nginx_container_env }}"
networks: "{{ nextcloud_nginx_container_networks | default(omit) }}" networks: "{{ nextcloud_nginx_container_networks | default(omit) }}"
restart_policy: "{{ nextcloud_nginx_container_restart_policy }}" restart_policy: "{{ nextcloud_nginx_container_restart_policy }}"
state: started state: started