????1?????????????
[root@linux-node1 base]# vim /etc/salt/master
file_roots:
base:
- /srv/salt/base
test:
- /srv/salt/test
prod:
- /srv/salt/prod
????#???top.sls???????base?????£???/srv/salt/base???£?
????[root@linux-node1 base]# /etc/init.d/salt-master restart
????#????Master??????Ч
????[root@linux-node1 base]# mkdir /srv/salt/{base??test??prod} -p
????#??????
????[root@linux-node1 base]# cd /srv/salt/
????[root@linux-node1 base]# mv apache.sls top.sls base/
????[root@linux-node1 base]# cd /srv/salt/base/
????[root@linux-node1 base]# mkdir files
????[root@linux-node1 base]# cp /etc/resolv.conf /srv/salt/base/files/
????2????????з???
????1????????
????[root@linux-node1 base]#salt '*' state.sls dns
????2?????top.sls??и????
????[root@linux-node1 base]# vim /srv/salt/base/top.sls
????base:
????'*':
????- dns
????[root@linux-node1 base]# salt '*' state.highstate