diff --git a/pages/common/salt b/pages/common/salt new file mode 100644 index 0000000000..5cae8ed81c --- /dev/null +++ b/pages/common/salt @@ -0,0 +1,18 @@ +#salt +>Execute commands and assert state on remote salt minions. + +- List connected minions + +`salt '*' test.ping` + +- Execute a highstate on all connected minions: + +`salt '*' state.highstate + +- Upgrade packages using the OS package manager (apt, yum, brew) on a subset of minions + +`salt '*.domain.com' pkg.upgrade + +- Execute an arbitrary command on a particular minion: + +`salt '{{minion_id}}' cmd.run "ls " diff --git a/pages/common/salt-call.md b/pages/common/salt-call.md new file mode 100644 index 0000000000..c76c46b644 --- /dev/null +++ b/pages/common/salt-call.md @@ -0,0 +1,18 @@ +# salt-key +> Invoke salt locally on a salt minion. + +- Perform a highstate on this minion + +`salt-call state.highstate` + +- Perform a highstate dry-run, compute all changes but don't actually perform them + +`salt-call state.highstate test=true` + +- Perform a highstate with verbose debugging output + +`salt-call -l debug state.highstate` + +- List this minion's grains + +`salt-call grains.items` diff --git a/pages/common/salt-key.md b/pages/common/salt-key.md new file mode 100644 index 0000000000..47346cbcaa --- /dev/null +++ b/pages/common/salt-key.md @@ -0,0 +1,16 @@ +# salt-key +> Manages salt minion keys on the salt master +> Needs to be run on the salt master, likely as root or with sudo + +- List all accepted, unaccepted and rejected minion keys + +`salt-key -L` + +- Accept or reject a minion key by name + +`salt-key -a {{MINION_ID}}` +`salt-key -r {{MINION_ID}}` + +- Print fingerprints of all public keys + +`salt-key -F` diff --git a/pages/common/salt-run b/pages/common/salt-run new file mode 100644 index 0000000000..f2798e88fc --- /dev/null +++ b/pages/common/salt-run @@ -0,0 +1,10 @@ +#salt-run +>Frontend for executing salt-runners on minions + +- Show status of all minions + +`salt-run manage.status` + +- Show all minions which are disconnected + +`salt-run manage.up`