file: Overhaul file resource and add recursion
The file resource contained some of the early golang code that I wrote for this project. Needless to say, some of it was quite yucky, and it was also lacking a number of important features. This patch builds upon it so that it starts being usable for directories of files too. Many thanks to Sam Gélineau for helping with the recursive watching. My brain officially didn't want to look at that code anymore.
This commit is contained in:
13
examples/file2.yaml
Normal file
13
examples/file2.yaml
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
graph: mygraph
|
||||
resources:
|
||||
noop:
|
||||
- name: noop1
|
||||
file:
|
||||
- name: file1
|
||||
path: "/tmp/mgmt/hello/"
|
||||
source: "/var/lib/mgmt/files/some_dir/"
|
||||
recurse: true
|
||||
force: true
|
||||
state: exists
|
||||
edges: []
|
||||
Reference in New Issue
Block a user