The check Thorium state is used to create gateways to commands, the checks make it easy to make states that watch registers for changes and then just succeed or fail based on the state of the register, this creates the pattern of having a command execution get gated by a check state via a requisite.
Only succeed if the value in the given register location contains the given value
USAGE:
foo:
check.contains:
- value: itni
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the value in the given register location is equal to the given value
USAGE:
foo:
check.eq:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Chekcs for a specific event match and returns result True if the match happens
USAGE:
salt/foo/*/bar:
check.event
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: salt/foo/*/bar
Only succeed if the value in the given register location is greater than the given value
USAGE:
foo:
check.gt:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the value in the given register location is greater or equal than the given value
USAGE:
foo:
check.gte:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the length of the given register location is equal to the given value.
USAGE:
foo:
check.len_eq:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if length of the given register location is greater than the given value.
USAGE:
foo:
check.len_gt:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the length of the given register location is greater or equal than the given value
USAGE:
foo:
check.len_gte:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the length of the given register location is less than the given value.
USAGE:
foo:
check.len_lt:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the length of the given register location is less than or equal the given value
USAGE:
foo:
check.len_lte:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the length of the given register location is not equal to the given value.
USAGE:
foo:
check.len_ne:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the value in the given register location is less than the given value
USAGE:
foo:
check.lt:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the value in the given register location is less than or equal the given value
USAGE:
foo:
check.lte:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo
Only succeed if the value in the given register location is not equal to the given value
USAGE:
foo:
check.ne:
- value: 42
run_remote_ex:
local.cmd:
- tgt: '*'
- func: test.ping
- require:
- check: foo