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

Use juju commands instead of yaml files? #32

Closed
tvansteenburgh opened this issue Dec 12, 2016 · 2 comments
Closed

Use juju commands instead of yaml files? #32

tvansteenburgh opened this issue Dec 12, 2016 · 2 comments
Labels
priority/low low priority

Comments

@tvansteenburgh
Copy link
Contributor

When using connection shortcuts like connect_current() and connect_model(), the information necessary to make the connection is obtained from yaml files in ~/.local/share/juju/.

I just saw a case where a model was present (showed in the output of juju list-models), yet did not exist in ~/.local/share/juju/models.yaml yet.

To avoid this we should use the output of juju commands instead of using the yaml files directly. Either way assumes the juju cli is installed. To connect without the juju cli installed, the plain connect() method can be used.

@sfeole
Copy link
Contributor

sfeole commented Dec 12, 2016

The only time I've seen a problem is when creating a new model via the api,

After creating the model, juju list-models via the CLI did not reflect that the model existed only until I deployed something to the newly created model. But I think that's by design.

I believe the act of creating a model does write to ~/.local/share/juju/model.yaml right? Also I noticed when the model is deleted via the API, it does not remove itself from ~/.local/share/juju/model.yaml file.

This is not the standard case when a model is created/destroyed via the juju commands

@arosales arosales added the priority/low low priority label Feb 23, 2017
@SimonRichardson
Copy link
Member

Closing this, if you think we should reopen it please do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority/low low priority
Projects
None yet
Development

No branches or pull requests

4 participants