New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix masterless jinja imports #54780
Fix masterless jinja imports #54780
Conversation
re-run full all |
0939d4e
to
43e67a2
Compare
43e67a2
to
00eba43
Compare
00eba43
to
6aea83a
Compare
I've pulled the Still getting:
|
@kiemlicz this PR adds a test which covers the proposed fix. It seems that what you're trying to do is to "push" the fix to the minions through your state tree. That should be filed as a separate issue so we can better track it. It's not related to the change this PR is addressing. |
re-run full all |
The addition of fileclient caching in the JinjaCacheLoader has broken all jinja imports in state files, in masterless salt-call runs. This is because masterless Pillar compilation uses the `PillarClient` while regular file caching (states, etc.) use the `LocalClient`. Since Pillar is compiled first in the masterless run, the class-level attribute where the cached fileclient is stored only ever usese the PillarClient, and thus any Jinja imports will cache the templates to the wrong location (under `pillar_roots`). This expands the cached fileclient support to distinguish between pillar and non-pillar, and keep a separate cached fileclient for each.
29b31fc
to
e901a83
Compare
This PR has the same patch as #54774 and adds tests |
@s0undt3ch thanks for reply, now I'm truly disappointed I know I can override the execution modules, state modules etc. using e.g. Overriding the local installed file: |
What does this PR do?
Fixes and adds tests for #54765 #54768
Tests written?
Yes
Commits signed with GPG?
Yes