--
You received this message because you are subscribed to the Google Groups "Salt-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
rolling_deployment.sls:
{% set minions = salt.saltutil.runner('cache.mine', tgt='G@location:uk', expr_form='compound') %}
{% for minion_id in minions %}
deploy_{{ minion_id }}:
salt.function:
- tgt: {{ minion_id }}
- name: cmd.run
- kwarg:
cmd: echo "Deploying {{ minion_id }}"
{% endfor %}
I changed 'cache.grains' to 'cache.mine' so that it doesn't print out all grains for all minions, but I'm not sure if it will cause any issues.
Are there any scenarios where using the cache runner altogether can be unreliable?
Below is the output of running the orchestration state:
salt-run state.orchestrate orch.rolling_deployment
Exception RuntimeError: 'maximum recursion depth exceeded while calling a Python object' in <type 'exceptions.AttributeError'> ignored
hostname2.localdomain.net:
----------
hostname1.localdomain.net:
----------
saltmaster1.localdomain.net_master:
----------
ID: deploy_hostname1.localdomain.net
Function: salt.function
Name: cmd.run
Result: True
Comment: Function ran successfully. Function cmd.run ran on hostname1.localdomain.net.
Started: 22:06:38.756495
Duration: 255.561 ms
Changes:
hostname1.localdomain.net:
Deploying hostname1.localdomain.net
----------
ID: deploy_hostname2.localdomain.net
Function: salt.function
Name: cmd.run
Result: True
Comment: Function ran successfully. Function cmd.run ran on hostname2.localdomain.net.
Started: 22:06:39.012409
Duration: 254.963 ms
Changes:
hostname2.localdomain.net:
Deploying hostname2.localdomain.net
Summary
------------
Succeeded: 2 (changed=2)
Failed: 0
------------
Total states run: 2
Is the python recursion error something I should be worried about? I'm running salt off of a RedHat 6 / python2.6 environment.
Thanks!