Skip to content

Commit 902d4ff

Browse files
authored
Add PID templating option (#267)
1 parent 77ccf86 commit 902d4ff

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

defaults/main/template.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ nginx_main_template:
1818
user: nginx
1919
worker_processes: auto
2020
# worker_rlimit_nofile: 1024
21+
pid: /var/run/nginx.pid
2122
error_log:
2223
location: /var/log/nginx/error.log
2324
level: warn

molecule/common/playbook_template.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
conf_file_location: /etc/nginx/
1414
user: nginx
1515
worker_processes: auto
16+
pid: /var/run/nginx.pid
1617
error_log:
1718
location: /var/log/nginx/error.log
1819
level: warn

templates/nginx.conf.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ worker_rlimit_nofile {{ nginx_main_template.worker_rlimit_nofile }};
4545
{% endif %}
4646

4747
error_log {{ nginx_main_template.error_log.location }} {{ nginx_main_template.error_log.level }};
48-
pid /var/run/nginx.pid;
48+
pid {{ nginx_main_template.pid }};
4949

5050

5151
events {

0 commit comments

Comments
 (0)