You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
state.top does not take/obey saltenv argument #10660
We need to make state.top take a saltenv argument which will limit the search to only that environment. This allows state.top to be used to trigger a versioned highstate from a given branch in gitfs, for example, without having to have a different name for the topfile in each branch.
Based on the source state.highstate does accept (and has for a while: #4474) a saltenv kwarg that's undocumented, and seems to point to a very simple similar solution for state.top as well as a possible workaround: set 'environment' in the minion config.
Another workaround might be the obscure - but documented - 'localconfig' param.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.
Activity
alex-solidfire commentedon Sep 30, 2014
I was about to open a new issue about state.highstate and saltenv. Could you add this also please?
basepi commentedon Oct 1, 2014
Probably will be similar code. Thanks for finding this issue and posting here. =)
somenick commentedon Jan 27, 2015
Based on the source state.highstate does accept (and has for a while: #4474) a saltenv kwarg that's undocumented, and seems to point to a very simple similar solution for state.top as well as a possible workaround: set 'environment' in the minion config.
Another workaround might be the obscure - but documented - 'localconfig' param.
It is a bit confusing because http://docs.saltstack.com/en/latest/ref/configuration/minion.html#environment explicitly mentions the top file for something it can't be used for: defining the environments is indeed best done in top files, but picking the environment can only be (officially) done in the minion config since saltenv doesn't work/is undocumented for the two methods that actually use them.
maybe this should be reclassified as a low hanging fruit bug...
alex-solidfire commentedon Jan 27, 2015
Thanks @somenick . We will give this a shot.
stale commentedon Oct 2, 2017
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.