Skip to content

Commit 768746c

Browse files
authored
fix: backup parameter of stream templates (#571)
1 parent 42129e9 commit 768746c

File tree

5 files changed

+5
-1
lines changed

5 files changed

+5
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ BUG FIXES:
1717
- The default PID path has changed as of NGINX 1.27.5 and 1.28.0.
1818
- Properly wrap `http_version` number in quotes in both the template defaults and Molecule tests.
1919
- NGINX `set_real_ip_from` directive template parameter should be a list.
20+
- Fix backup parameter for stream templates.
2021

2122
TESTS:
2223

defaults/main/template.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -794,6 +794,7 @@ nginx_config_stream_template_enable: false
794794
nginx_config_stream_template:
795795
- template_file: stream/default.conf.j2
796796
deployment_location: /etc/nginx/conf.d/streams/stream_default.conf
797+
backup: true
797798
config:
798799
upstreams: # Configure upstreams
799800
- name: stream_upstream # Required

molecule/complete/converge.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -760,6 +760,7 @@
760760
nginx_config_stream_template:
761761
- template_file: stream/default.conf.j2
762762
deployment_location: /etc/nginx/conf.d/streams/stream_default.conf
763+
backup: true
763764
config:
764765
upstreams:
765766
- name: stream_upstream

molecule/complete_plus/converge.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -656,6 +656,7 @@
656656
nginx_config_stream_template:
657657
- template_file: stream/default.conf.j2
658658
deployment_location: /etc/nginx/conf.d/streams/stream_default.conf
659+
backup: true
659660
config:
660661
upstreams:
661662
- name: stream_upstream

tasks/config/template-config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@
121121
ansible.builtin.template:
122122
src: "{{ item['template_file'] | default('stream/default.conf.j2') }}"
123123
dest: "{{ item['deployment_location'] | default('/etc/nginx/conf.d/stream/stream_default.conf') }}"
124-
backup: true
124+
backup: "{{ item['backup'] | default(true) }}"
125125
mode: "0644"
126126
loop: "{{ nginx_config_stream_template }}"
127127
loop_control:

0 commit comments

Comments
 (0)