/srv/irclogs.ubuntu.com/2017/12/19/#juju.txt

=== frankban|afk is now known as frankban
=== rogpeppe1 is now known as rogpeppe
gnuoy'--map-machines' hurray ! thank you juju team14:52
=== frankban is now known as frankban|afk
skayhow do I get a list of resources that have been attached?18:28
skayfrom the command line18:29
rick_hskay: juju resources $app ?18:32
skayrick_h: dangit. why was that not working before18:32
rick_hskay: sorry, not sure18:33
skayoh, 'dangit' was mock self-deprecation. I just realized that might not carry over irc.18:34
skayno need to apologize18:34
rick_hskay: :) sorry assumed you meant you tried it and didn't get any response from the command18:34
* rick_h is in default "it's broken" mode today evidently18:34
skayyes, I did before, and thus got confused thinking perhaps it was only meant to show resources in the store18:34
skaybut after youmentioned it, I tried again. it listed the resources I had attached18:35
skayI question my reality. it was a glitch in the matrix18:35
rick_hno, I think that's a different command. juju charm --help18:35
skayk18:35
rick_hskay: so it's a little confusing. We want to keep split those commands that touch the store vs just the current model18:35
skayoh! earlier I had called the charm-resources command. makes sense now18:36
skayreality is restored18:36
rick_hskay: yay18:37
skayI've been deploying and redeploying things to see if there is some race condition that makes one of my subordinates not realize there is a resource18:37
skayI thought it was happening, but it may just be that I wasn't waiting long enough for things to settle18:37
skaywhen someone attaches a resource right after a juju deploy, and thus before a machine is ready, I'm assuming that the unit will detect the resource once the unit is ready18:39
rick_hskay: well, it might take a bit for the resource to be fetched18:39
skayok18:39
rick_hskay: the fetching is done in the context of other hooks that say "go get it"18:39
skayhmm, I think I don't have a problem, I was just impatient18:39
skayI have the charm look for a resource in the check status hook18:40
rick_hupdate-status hook?18:40
rick_hyea, so that might take a 30s run up from the charm hitting stable and then it will download/etc18:40
rick_hthough should download from the controller and be pretty quick18:41
skayoh I lie, I only thought I did18:41
skayI have it in the upgrade-charm hook, because that is triggered with the attach command18:41
skaywill the upgrade-charm hook get triggered by the attach command that happened before the unit was up?18:42
rick_hskay: so since hooks are serliazed it just means update-status hook will get put in line18:43
skayalso, would it be more appropriate to check for the attached resources in the update-status hook? currently I only have it check some flags18:44
skayI didn't set up a handler to run everytime the flag is not set, becuase I thought that would be too often18:44
rick_hwell running attach will trigger the update-status hook. so you want whatever to be hit from there but could be part of install/etc since on deploy you could have the resource there18:45
rick_h  from --help: juju deploy foo --resource bar=/some/file.tgz --resource baz=./docs/cfg.xml18:45
skayin reality, I'm deploying from a bundle (the jujubundle and not the juju2 bundle) and don't have the resource defined in the bundle18:47
skayonce I deploy the bundle, I wait for things to settle, then run the attach commands18:47
skayat this point resources may be able to be defined in bundles, I should check18:47
rick_hah, gotcha18:47
rick_hskay: https://github.com/juju/charm/blob/v6/bundledata.go#L154 implies yes as part of defining the application18:48
rick_hskay: but it can be revisions of the resource in the store.18:49
rick_hthere was a task to allow specifying local resources but not sure it's in place18:49
skayat this point, maybe I should not use mojo to deploy a bundle and use juju deploy <bundle> instead18:49
skaymojo collect, build, etc are useful18:50
skayfound the docs for charm bundles https://jujucharms.com/docs/stable/charms-bundles#bundles-and-charm-resources18:52
skaysorry, re mojo, I meant juju-deployer config files, not bundles18:56
skaymojo uses that. the syntax is similar, but different18:56
skayfor future reference, juju-deployer config file has similar syntax for resources19:03
prime-ribzhello all, can someone point me in the direction of how to add security group rules for aws in the model config? would like to add a ingress rule when I pass "juju add-model".19:37
pmatulisin principle that is doable but i haven't seen that level of config yet. i'm not a dev though20:15
prime-ribzpmatulis : Thanks will keep searching for a work around.20:35

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!