http://bugzilla.opensuse.org/show_bug.cgi?id=1123680 Bug ID: 1123680 Summary: salt file.managed broken Classification: openSUSE Product: openSUSE.org Version: unspecified Hardware: x86-64 OS: SLES 12 Status: NEW Severity: Major Priority: P5 - None Component: 3rd party software Assignee: bnc-team-screening@forge.provo.novell.com Reporter: ds-tg@surfsara.nl QA Contact: bnc-team-screening@forge.provo.novell.com Found By: --- Blocker: ---
From "https://build.opensuse.org/package/show/systemsmanagement:saltstack/salt"
The salt-2016.11.4-25.1 package breaks file.managed entirely. A sample output of a single state applying file.managed to copy a file to a minion. ``` ---------- ID: Copying baseline file Function: file.managed Name: /tmp/testModule Result: False Comment: Unable to manage file: 'module' object has no attribute 'path' Started: 16:20:35.437762 Duration: 19.129 ms Changes: ``` The problem is: despite failing, the file is actually copied. The state continues on, though any "watch" flags on this state specifically never trigger as a file modified. So if you use file.managed to maintain a service configuration file, a "watch" state to restart the service on change would never trigger, even though the file actually is changed. This here is a very simple init.sls that can use file.managed to copy a file, append a date, and if file is modified, append a "WATCHED" flag to the file. ``` #Created for testing file.managed Copying baseline file: file.managed: - name: /tmp/testModule - source: salt://testModule/testFile - backup: False - show_changes: True "date >> /tmp/fileModule": cmd.run "echo 'Watch Triggered' >> /tmp/fileModule": cmd.run: - onchanges: - file: /tmp/fileModule ``` You just need a simple 1 test file to act as the source of the file.managed. ---- This was resolved by downgrading to salt-2016.11.4-23.1 on all systems. -- You are receiving this mail because: You are on the CC list for the bug.