Skip to content
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

'defaults.merge' is not available when using salt-ssh #51605

Open
myii opened this issue Feb 12, 2019 · 6 comments · Fixed by #65517
Open

'defaults.merge' is not available when using salt-ssh #51605

myii opened this issue Feb 12, 2019 · 6 comments · Fixed by #65517
Labels
Bug broken, incorrect, or confusing behavior severity-medium 3rd level, incorrect or bad functionality, confusing and lacks a work around
Milestone

Comments

@myii
Copy link
Contributor

myii commented Feb 12, 2019

Description of Issue/Question

SaltStack-Formulas has started to adopt using defaults.merge in map.jinja, for example in the salt-formula.

There are now two reports that this isn't working when using salt-ssh. Both with the same error:

[DEBUG   ] Could not LazyLoad defaults.merge: 'defaults.merge' is not available.

This is an unfortunate development, since we're making a concerted effort to improve the quality and usefulness of SaltStack-Formulas in general. For reference:

Setup

The redis-formula issue has full details.

Steps to Reproduce Issue

Covered in the issue above.

Versions Report

Covered in the issue above.
Also supplied in the openssh-formula pull comment.

alxwr added a commit to alxwr/template-formula that referenced this issue Feb 12, 2019
because defaults.merge does not work with salt-ssh.
saltstack/salt#51605

Added osfingermap.yaml.
alxwr added a commit to alxwr/template-formula that referenced this issue Feb 12, 2019
because defaults.merge does not work with salt-ssh.
saltstack/salt#51605

Added osfingermap.yaml.
alxwr added a commit to alxwr/template-formula that referenced this issue Feb 12, 2019
because defaults.merge does not work with salt-ssh.
saltstack/salt#51605

Added osfingermap.yaml.
alxwr added a commit to alxwr/apache-formula that referenced this issue Feb 13, 2019
@Ch3LL
Copy link
Contributor

Ch3LL commented Feb 13, 2019

looks like i'm able to replicate this error running the following:

  1. cd /srv/salt
  2. git clone https://github.com/saltstack-formulas/redis-formula.git .
  3. salt-ssh '*' state.sls redis test=True -ltrace > /tmp/test 2>&1

and i see - Rendering SLS 'base:redis.common' failed: Jinja variable 'dict object' has no attribute 'pkg_name'

looks like we need to get this fixed up thanks

@Ch3LL Ch3LL added Bug broken, incorrect, or confusing behavior severity-medium 3rd level, incorrect or bad functionality, confusing and lacks a work around P2 Priority 2 team-ssh triage labels Feb 13, 2019
@Ch3LL Ch3LL added this to the Approved milestone Feb 13, 2019
@myii
Copy link
Contributor Author

myii commented Feb 13, 2019

@Ch3LL Thanks for the review and confirmation.

and i see - Rendering SLS 'base:redis.common' failed: Jinja variable 'dict object' has no attribute 'pkg_name'

Yes, as a symptom of the merge not taking place, the other YAML files are not merged into the map, leading to missing attributes as shown in the following two comments:

@yuriks
Copy link

yuriks commented Mar 20, 2020

For anyone stumbling on this: You can use slsutil.merge to do exactly the same thing.

@myii
Copy link
Contributor Author

myii commented Mar 20, 2020

@yuriks Thanks for sharing that. Actually, we've got an active PR that proposes the same thing:

vincentor pushed a commit to vincentor/salt-formula that referenced this issue Apr 28, 2020
@vincentor
Copy link

@yuriks looks like slsutil.merge isn't working in the salt-ssh situation too

vincentor pushed a commit to vincentor/salt-formula that referenced this issue Apr 29, 2020
@sagetherage sagetherage removed the P2 Priority 2 label Jun 3, 2020
jzandbergen added a commit to jzandbergen/salt-formula that referenced this issue Feb 7, 2022
@nergdron
Copy link

just got bit by this as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug broken, incorrect, or confusing behavior severity-medium 3rd level, incorrect or bad functionality, confusing and lacks a work around
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants