Skip to content

[BUG] Service is not reloaded when snippets are added #291

@sticky-note

Description

@sticky-note

Your setup

Formula commit hash / release tag

nginx-formula v2.6.0

Versions reports (master & minion)

Both master and minon: salt version 3003

Pillar / config used

My nginx.conf is like:

...
http {
  ...
  include snippets/*.cnf
  ...
}

Add this snippet on a second state.highstate run

nginx:
  snippets:
+    global.cnf:
+      - underscore_in_header: 'on'

Bug details

Describe the bug

  • Run a highstate with nginx-formula included
    First run is ok, nginx is started with nginx.conf above

  • Add snippet above
    Run a second state.highstate
    Nginx service do not get reloaded on the second run
    Changes are not taken iinto account.

minion.org.com:
          ID: nginx_snippet_global.cnf
    Function: file.managed
        Name: /usr/local/etc/nginx/snippets/global.cnf
      Result: True
     Comment: File /usr/local/etc/nginx/snippets/global.cnf updated
     Started: 18:52:03.020966
    Duration: 1665.896 ms
     Changes:   
              ----------
              diff:
                  New file
              mode:
                  0644

Summary for minion.org.com
--------------
Succeeded: 143 (changed=1)
Failed:      0
--------------
Total states run:     143
Total run time:    57.696 s

Steps to reproduce the bug

state.apply nginx two times with a new snippet the second time.

Expected behaviour

Reload of nginx service when we add new snippets

Attempts to fix the bug

Additional context

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions