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

expand user home when deserializing configuration #304

Merged
merged 4 commits into from
Jan 12, 2019

Conversation

dbarrosop
Copy link
Contributor

No description provided.

@ogenstad
Copy link
Collaborator

ogenstad commented Jan 6, 2019

This would still cause the documentation to become incorrect?

@floatingstatic
Copy link
Contributor

@dbarrosop I tested this and it appears to be working. 👍
For what it's worth, without your changes or those in my PR I was able to work around this in 2.0.0 by doing this in InitNornir:

    nr = InitNornir(
        inventory={
            "plugin": "my.custom.inventory",
            "options": {
                "blah": kwargs["blah"],
            },
        },
        core={"num_workers": 20, "raise_on_error": True},
        dry_run=False,
        ssh={"config_file": os.path.join(os.path.expanduser("~"), ".ssh", "config")},
    )

Running with your branch I can now omit the ssh config_file override and get the same result.

@dbarrosop
Copy link
Contributor Author

It shouldn't, the schema hasn't changed and the configuration is generated from it.

Copy link
Collaborator

@ogenstad ogenstad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My bad I didn't look close enough, thought that it was just a variation of the other PR. LGTM.

@dbarrosop dbarrosop merged commit 76247d3 into develop Jan 12, 2019
@dbarrosop dbarrosop deleted the expand_ssh_config branch August 3, 2019 11:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants