I'm working on configuring a group of 40 servers to be managed by SaltStack. I'm testing with just one minion at the moment, which I have successfully added to the master. For simplicity, I'm using the latest version of salt and salt-minion from the Ubuntu 14.04.1 package repository on the respective machines.
I have what appears to be a sane configuration and directory structure, however whenever I try running salt '*' state.highstate
, I get an error that the top file does not match the nodes. If I try manually running a state file with salt '*' state.sls worker.users
, it errors that no such file exists. Directory structure and files are below.
Any idea why this is not working?
root@salt-master:/srv/salt# tree /srv/salt
/srv/salt
├── worker
│ └── users.sls
└── top.sls
1 directory, 4 files
root@master:/srv/salt# salt '*' state.highstate
worker-2:
----------
State: - no
Name: states
Function: None
Result: False
Comment: No Top file or external nodes data matches found
Changes:
Summary
------------
Succeeded: 0
Failed: 1
------------
Total: 1
The contents of the relevant files:
root@master:/srv/salt# cat top.sls
base:
'*':
- worker.users
root@master:/srv/salt# cat worker/users.sls
worker:
user.present:
- fullname: Service Account
- shell: /bin/bash
- home: /home/worker
admin:
user.present:
- fullname: Search Admin Account
- shell: /bin/bash
- home: /home/admin
File root is defined as follows in the master and I've restarted all the machines:
file_roots:
base:
- /srv/salt