saltstack / saltstack/salt

reactor orchestrate runner not executing, no errors

Open
#50,827 9 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug Confirmed severity-medium
Dominant language
Python
Stars
15.7k
Forks
5.6k
Avg merge
2d 44m
Merged PRs (30d)
80

Description

I have been setting up the reactor states in our salt environment for the first time.
The local.state.single reactor states working. However, there is a need to use runner.state.orchestrate.

After reading all the past issues and examples I have found for the numerous variations of reactor state syntax specifically around passing pillar to the underlying orchestrate state, I have one config that at least isn't throwing errors in the master log.
I know the event is firing from a minion and it's being detected as the reactor state executes. However, the orchestrate state that IT is supposed to execute isn't firing. I assume it's not because the change doesn't take place and there's nothing in the master log.

Reactor config in master

reactor:
    - 'orch/group/role/do_the_thing':
    - salt://reactor/orch/common/role/test_do_the_thing.sls?saltenv=test

Reactor state

test_do_the_thing_reactor:
  runner.state.orchestrate:
    - mods: orch.common.role.do_the_thing
    - kwarg:
       pillar:
         minion: {{ data['data']['minion'] }}, 
         role: {{ data['data']['role'] }}, 
         action: {{ data['data']['action'] }}

I fire the event from a minion with this (for reference, this works fine)

orch/group/role/do_the_thing:
  event.send:
    - data:
         role: "myrole"
         minion: {{grains['other-minions']|join(',')}}
         action: "some cmdline action"

Here's my salt version dump:

Salt Version:
           Salt: 2017.7.5
 
Dependency Versions:
           cffi: Not Installed
       cherrypy: Not Installed
       dateutil: 2.6.1
      docker-py: Not Installed
          gitdb: 2.0.3
      gitpython: 2.1.9
          ioflo: Not Installed
         Jinja2: 2.7.2
        libgit2: Not Installed
        libnacl: Not Installed
       M2Crypto: Not Installed
           Mako: Not Installed
   msgpack-pure: Not Installed
 msgpack-python: 0.4.6
   mysql-python: Not Installed
      pycparser: Not Installed
       pycrypto: 2.6.1
   pycryptodome: Not Installed
         pygit2: Not Installed
         Python: 2.7.5 (default, Aug  4 2017, 00:39:18)
   python-gnupg: Not Installed
         PyYAML: 3.10
          PyZMQ: 15.3.0
           RAET: Not Installed
          smmap: 2.0.3
        timelib: Not Installed
        Tornado: 4.2.1
            ZMQ: 4.1.4
 
System Versions:
           dist: centos 7.4.1708 Core
         locale: UTF-8
        machine: x86_64
        release: 3.10.0-693.11.6.el7.x86_64
         system: Linux
        version: CentOS Linux 7.4.1708 Core

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the master reactor configuration and the minion event shown in the issue, then trace the runner.state.orchestrate entry point and its pillar handoff. Compare the event detection with whether orch.common.role.do_the_thing is invoked; done means the orchestrate state executes and produces observable master output.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.