Friday, 2021-04-16

*** avass has quit IRC00:26
*** hamalq has quit IRC01:53
*** evrardjp has quit IRC02:33
*** evrardjp has joined #zuul02:33
openstackgerritJames E. Blair proposed zuul/zuul master: Revert "Revert "Make repo state buildset global""  https://review.opendev.org/c/zuul/zuul/+/78553503:18
openstackgerritJames E. Blair proposed zuul/zuul master: Fix missing repo state restore  https://review.opendev.org/c/zuul/zuul/+/78531003:18
openstackgerritJames E. Blair proposed zuul/zuul master: Keep jobgraphs frozen across reconfiguration  https://review.opendev.org/c/zuul/zuul/+/78553603:18
openstackgerritJames E. Blair proposed zuul/zuul master: Add a fast-forward test  https://review.opendev.org/c/zuul/zuul/+/78652103:18
openstackgerritJames E. Blair proposed zuul/zuul master: Correct repo_state format in isUpdateNeeded  https://review.opendev.org/c/zuul/zuul/+/78652203:18
openstackgerritJames E. Blair proposed zuul/zuul master: Restore repo state in checkoutBranch  https://review.opendev.org/c/zuul/zuul/+/78652303:18
corvusclarkb, tobiash: ^ erm, that opened a can of worms.  i believe the isUpdateNeeded method is not currently doing anything and may not have for some time.  it may never have.  i left that as a series of patches to try to untangle this.  start at 786512 and go down the stack from there.  i *think* that by the end everything should work, but i haven't run the whole test suite yet; there could still be more work03:26
corvusto do.  when we are done, we'll still need to squash.03:26
*** rlandy|rover|bbl has quit IRC03:47
*** ykarel has joined #zuul04:15
*** jfoufas1 has joined #zuul04:24
*** vishalmanchanda has joined #zuul04:30
*** bhavikdbavishi has joined #zuul04:30
*** bhavikdbavishi has quit IRC04:32
*** saneax has joined #zuul05:42
lyrHi there. FYI there's a broken link in this doc, between 2nd & 3rd code bloc https://zuul-ci.org/docs/zuul/discussion/encryption.html#encryption06:35
*** jcapitao has joined #zuul06:38
*** zbr has quit IRC06:56
*** zbr has joined #zuul06:58
*** avass has joined #zuul07:00
*** ykarel_ has joined #zuul07:00
*** ykarel has quit IRC07:02
*** holser has quit IRC07:13
*** ykarel_ has quit IRC07:15
*** ykarel has joined #zuul07:17
*** bhavikdbavishi has joined #zuul07:30
*** jpena|off is now known as jpena07:30
*** rpittau|afk is now known as rpittau07:32
*** harrymichal has joined #zuul07:34
*** bhavikdbavishi has quit IRC07:37
*** harrymichal has quit IRC07:39
*** tosky has joined #zuul07:39
*** harrymichal has joined #zuul07:39
*** harrymichal_ has joined #zuul07:41
*** harrymichal has quit IRC07:44
*** harrymichal_ is now known as harrymichal07:44
*** harrymichal has quit IRC08:22
*** harrymichal has joined #zuul08:22
*** travier has joined #zuul08:40
* harrymichal waves at travier08:40
*** ykarel is now known as ykarel|lunch08:44
*** ykarel|lunch has quit IRC08:48
*** bhavikdbavishi has joined #zuul08:53
*** bhavikdbavishi1 has joined #zuul08:55
*** bhavikdbavishi has quit IRC08:57
*** bhavikdbavishi1 is now known as bhavikdbavishi08:57
*** harrymichal has quit IRC08:59
*** harrymichal has joined #zuul08:59
*** harrymichal has quit IRC09:17
*** harrymichal has joined #zuul09:17
*** harrymichal has quit IRC09:19
*** harrymichal has joined #zuul09:19
*** ykarel has joined #zuul09:38
*** jcapitao has quit IRC09:45
*** jcapitao has joined #zuul09:46
*** holser has joined #zuul10:10
*** bhavikdbavishi has quit IRC10:25
*** jcapitao is now known as jcapitao_lunch10:26
*** cloudnull has quit IRC11:09
*** cloudnull7 has joined #zuul11:09
*** jpena is now known as jpena|lunch11:32
*** rlandy has joined #zuul11:50
*** rlandy is now known as rlandy|rover11:50
*** jcapitao_lunch is now known as jcapitao12:09
*** bhavikdbavishi has joined #zuul12:24
*** bhavikdbavishi1 has joined #zuul12:27
*** bhavikdbavishi has quit IRC12:28
*** bhavikdbavishi1 is now known as bhavikdbavishi12:28
*** jpena|lunch is now known as jpena12:30
*** bhavikdbavishi has quit IRC12:39
*** VinayJain212 has joined #zuul13:22
VinayJain212Hi, what is best way to access log_url of current build in POST phase...I have script which needs log_url as input after CI is finished.13:24
avassVinayJain212: I think there either is a change on the way to expose that or it was recently. I can look it up in a couple of minutes13:25
VinayJain212avass - yes that would be great. So just to confirm its not possible in current version of zuul?13:27
*** sean-k-mooney has joined #zuul13:30
travierHi there. I have some questions related to https://github.com/containers/toolbox/issues/714. We're looking into adding Fedora CoreOS as a host for testing the containers/toolbox project. I gathered that everything is running on OpenStack and apparently we can pass userdata to test instances: https://zuul-ci.org/docs/nodepool/openstack.html#attr-providers.[openstack].pools.labels.userdata. Could this userdata be customized per test job triggered on Zuul or does it13:30
travier has to be fixed? Do we have to use Ansible for test jobs scripting or can we use shell scripts or something else? Thanks!13:30
sean-k-mooneythe vms are created by nodepool not zuul13:31
sean-k-mooneyand you cant pass custimised data to nodepool form zuul as part of the job defintion13:32
sean-k-mooneytravier: so you cant pass per job user data no13:33
travierok, so we can set the userdata, but it will be the same for all jobs?13:33
travierok13:33
sean-k-mooneyit has to be the same for all uses of that lable13:33
sean-k-mooneyreally the way its intended to work is nodepool does what is nessalry to provde an env where ansible can connect13:33
travierwe can work with that13:33
sean-k-mooneythen you use ansibel for the rest of the customisation13:33
sean-k-mooneytravier: you can also reboot the nodes provide by nodepool so you could have an ansible srcipt coonect and write a file to the node and reboot it if that helps13:34
sean-k-mooneyi dont know if core os will pick that up and rerun ignition/cloud-init or not13:35
travierit won't we only run Ignition on first boot. And we don't have Python 313:36
sean-k-mooneyin 2021?13:36
travierI was also pointed to raw ansible modules13:36
travierWe don't have any Python ;)13:36
sean-k-mooneyah13:36
sean-k-mooneyya so you can use the raw ansible module to prep the env for ansible13:36
sean-k-mooneyi think i did that in kolla ansible13:37
sean-k-mooneythey remvoed it or moved it but like this13:39
sean-k-mooneyhttps://github.com/openstack/kolla-ansible/blob/stable/pike/ansible/roles/baremetal/tasks/pre-install.yml#L3-L813:39
sean-k-mooneyyou have to disable gathering facts untill python is avaiable13:39
sean-k-mooneyso i think you would need to do this in your base job13:39
sean-k-mooneyclarkb: do you know off the top of your head if we can list a different file for zuul to read when we list a repo13:41
travierHum, I'm sorry I'm asking weird questions, but do we really need to install Python? Can't we directly send the job commands as shell and gather output?13:42
sean-k-mooneyusecase is in downstream ci it woudl be nice if i could tell zuul to ignroe the .zuul.yaml form upstream and read .zuul-downstream.yaml isntead13:42
avassVinayJain212: it looks like upload_results.url is available if used in the same playbook as the log upload: https://opendev.org/opendev/base-jobs/src/branch/master/playbooks/base/post-logs.yaml#L3913:42
sean-k-mooneytravier: ansible requires python to work13:42
avassbut I'm pretty sure that is going to be deprecated for a different variable, or the same variable but set differently13:43
sean-k-mooneytravier: they shell and command module require it13:43
sean-k-mooneytravier:and simple json13:43
sean-k-mooneytravier: so unless you are only going to use the raw modules then yes you need python13:43
sean-k-mooneytravier: this is not a requiremnt of zuul its a requirement for using ansible13:44
travieryes, so the question is: can we use zuul without ansible?13:44
sean-k-mooneyno13:44
travierok13:45
travierwhat if I do everything in a raw module?13:45
sean-k-mooneyif you do everyting in the raw module then you dont obviously13:46
mordredThere's still base job operations, like getting the source code to the remote machine13:46
sean-k-mooneybut that is very limiting13:46
mordredSo you'd have to reimplement fundamental parts of the base jobs13:46
sean-k-mooneymordred: yep doing everything with raw would also have to mean rewriting that to use raw13:46
sean-k-mooneyyep13:47
mordredYup.13:47
avassVinayJain212: here: https://review.opendev.org/c/zuul/zuul-jobs/+/776677/6/roles/upload-logs-swift/tasks/main.yaml13:47
sean-k-mooneywhich kill the reusablity13:47
sean-k-mooneytravier: what is the objection to having python?13:47
mordredI mean, it's a computer, you CAN do anything :)13:47
travierWe have to do custom things anyway as we can not just install a pile of package on Fedore CoreOS, it's easier to just run everything inside of a container13:48
corvusVinayJain212, avass: don't rely on that variable; it will be removed; https://review.opendev.org/c/zuul/zuul-jobs/+/776677  should let you do what you want when it merges.13:48
avasscorvus: yeah that's what I was thinking of13:48
sean-k-mooneybut you can add some packages to core os13:49
sean-k-mooneytravier: you can use a python virtual env too by the way13:49
travierNothing against Python, it's just not installed by default on Fedora CoreOS13:49
corvustravier, mordred: wait, let's back up a bit about this "can i use zuul without ansible" thing...13:49
*** bhagyashris is now known as bhagyashris|away13:49
sean-k-mooneytravier: right but you could use the user-data to install it13:50
sean-k-mooneyi.e. have ignition prep the coreos instance so that you can use ansible13:50
*** saneax has quit IRC13:50
VinayJain212avass, corvus - how do I access this variable in build config. I tried using zuul_log_url but it fails.13:51
corvustravier, mordred: oh, nm, mordred covered the base jobs bit :)  so it's possible but you'd have to re-do a bnuch of work13:51
VinayJain212is there any example you can point me where log_url is used in config file.13:51
sean-k-mooneytravier: you could try binding mounting python form a contianer to the host and setting the python virtul enve dir for ansible to use that host mount13:51
sean-k-mooneytravier: really until https://github.com/coreos/fedora-coreos-tracker/issues/592 is resovle i dont think zuul can supprot it as a target distro13:53
avassVinayJain212: it's not yet merged so itäs not available yet. The only current option is to use upload_result.url but like corvus said it's going to be removed and it's only possible to use it in the same playbook that you upload logs in and only after the logs have been uploaded13:53
avassVinayJain212: so waiting for https://review.opendev.org/c/zuul/zuul-jobs/+/776677 to merge is preferable right now13:54
traviersean-k-mooney: yeah, it's ugly but I can do the python setup on first boot. Another question: you say Zuul is fine if the node reboots. Is it fine if it reboots in the middle of a playbook?13:56
travierbetween two commands13:56
sean-k-mooneytravier: you can use the playbook to reboot the node and then have the next command wait13:57
sean-k-mooneyand try an reconnect13:57
sean-k-mooneythen continue on13:57
sean-k-mooneyso like if you wanted to do a kernel update you could13:57
travierok, thanks13:58
*** hashar has joined #zuul14:01
corvustristanC: fyi see convo with travier ^14:03
*** ykarel has quit IRC14:03
travierWhat I'm planning to do based on this conversation:14:07
travier1. Add Fedora CoreOS QCOW2 images for all streams (stable, testing, next)14:07
travier2. Setup OpenStack userdata with Zuul SSH key for those images14:07
travier3. Use Raw Ansible module to install what's need for Ansible (Python 3, etc.) and update to latest version and reboot the node14:07
travier4. Use regular Ansible playbooks to run shell commands to run the job14:07
travierDo that looks reasonable to you?14:07
*** nils has joined #zuul14:08
sean-k-mooneytravier: i think so14:13
corvustravier: yep; note that #3 has to happen as the first thing in a pre-run playbook in a base job, which must be created in a trusted repo.14:14
sean-k-mooneydepending on what you are tryign to do it might make sense to spawn a container with a seconnd ssh server and have ansible connect to data by useing a different invenoty14:14
sean-k-mooneythen you could use other modules too14:14
travierwe need to be on the host to test container tools (toolbox)14:15
sean-k-mooneyi see ok14:15
sean-k-mooneytravier: why not just have python installe dvia user-data14:16
sean-k-mooneyfor that lable14:17
sean-k-mooneyin nodepool14:17
sean-k-mooneythen you would not need to take special stpes in the zuul jobs14:17
mordredyeah - that would save you from having to have a whole different ... yeah that ^^14:17
corvus++14:17
mordredthen you could still write a normal pre-playbook to do the update-and-reboot step if you wanted14:18
*** rpittau is now known as rpittau|afk14:18
mordredbut it could come after the normal base job pre playbook heirarchy14:18
sean-k-mooneytravier: you can have multiple lables refer to the same image by the way to14:18
travierI could indeed, maybe delaying starting ssh before that is completed14:19
sean-k-mooneyif you wanted a vanila lable and a fedora-coreOS-zuul lable14:19
tristanCtravier: that should work, you can find toolbox's zuul ssh key here: https://softwarefactory-project.io/keys/zuul_rsa.pub14:19
travierThanks everyone! Will give this a try first and we'll see if it works :)14:23
corvustravier: let us know if it works, or if we should brainstorm other ideas :)14:24
corvustravier: also thanks for toolbox14:24
travier^^ that's for harrymichal :) I'm a Fedora CoreOS dev :)14:25
corvusharrymichal: thanks for toolbox! travier thanks for making toolbox better on coreos! :)14:27
travier:)14:33
clarkbsean-k-mooney: there is a lot of scrollback. Did you get an answer to your question? I don't know what the answer is myself but I suspect that isn't currently supported14:37
sean-k-mooneyclarkb: no i didnt but i assume that is the case too14:37
harrymichalcorvus: :)14:37
sean-k-mooneyclarkb: currently we have a seperate config repoo that creates jobs on other pojects14:37
sean-k-mooneyand we just dont import jobs form the source code repos14:38
sean-k-mooneybut it would be nice to do it in tree14:38
sean-k-mooneyclarkb: i dont think it would be partically hard to add14:38
corvussean-k-mooney: you can add files, but not subtract them14:39
sean-k-mooneyyep14:39
sean-k-mooneyi have seen that14:39
sean-k-mooneyhttps://zuul-ci.org/docs/zuul/reference/tenants.html#attr-tenant.untrusted-projects.%3Cproject%3E.extra-config-paths14:40
sean-k-mooneyit would be nice if we could add a flag like disable_default_config_paths=true|false14:41
sean-k-mooneyif we had that we could set it to false and then use extra-config-path to point at the new one14:41
corvussean-k-mooney: so you want to manage two different zuul systems from the same repo?14:41
sean-k-mooneycorvus: kind of but no14:42
sean-k-mooneyits for our downstream copy of the nova repo14:42
sean-k-mooneyim trying to avoid touching the upstream .zuul.yaml file to avoid conflcits on rebases14:42
sean-k-mooneywhen we import chanage form stable branches14:43
sean-k-mooneyit woudl be nice if we coudl say in our donw stream config look at this additonal file14:43
sean-k-mooneyand ignore the default one14:43
sean-k-mooneythe curren approch is to use a configure repor to defien the jobs out of repo but that has the disadvatage of no speculative job execution14:44
corvussean-k-mooney: ok.  fwiw, when we designed zuul for that use case, we designed it to support that ^14:44
sean-k-mooneyto support 2 different zuuls form the same repo?14:45
corvusunderstandable if priorities are different; just wanted to mention that it was a design decision, not an omission14:45
corvusoh no14:45
*** jfoufas1 has quit IRC14:45
sean-k-mooneyoh i know why its the way it is14:45
corvussean-k-mooney: zuul is a gating system, so the idea of two zuuls being responsible for the same repo does not compute :)14:45
sean-k-mooneyit just make doing downstream ci harder14:45
sean-k-mooneywell we have 2 repos14:45
sean-k-mooneyand we would like zuul to be gating dowstream14:46
sean-k-mooneythe issue here is we periodicl rebase our downstream copy to pickup the stable fixes14:46
sean-k-mooneyand if we modifed the zuul file downstream it would confilt with upstream changes14:46
sean-k-mooneythat is why we defien jobs out fo tree downstream14:47
corvussean-k-mooney: right, i'm just saying at the time, we chose to solve that via using other repos.  note that you don't have to define those jobs in config repos14:47
sean-k-mooneyand since only config repos can define jobs for other repos we losse the ablity to test jobs before they merge without doing depens on and other hacks14:47
corvussean-k-mooney: you could have a "downstream-jobs" untrusted repo with your job definitions, and you only need a config project to tell zuul to run those jobs.14:47
corvusdepends-on is not a hack14:47
sean-k-mooneyits not a hack but we would have to defien the job in an untrusted repo and the piplene in a truesed one14:48
sean-k-mooneyso we go form 1 repo upstream to 3 downstream14:48
corvusright, but the project-pipeline doesn't change as often14:48
sean-k-mooneyture it s just an issue when adding new jobs14:49
corvusand yes, that's 2 more repos, but those 2 repos can serve all of your projects14:49
sean-k-mooneywhich is what im contimplating doing currently14:49
corvus(so if you have N openstack projects in this system, you'd only need N+2 repos downstream)14:49
sean-k-mooneyok i can do this but i was hoping i could just use one repo and override it in my tenatns file som how14:50
sean-k-mooneycorvus: ya the ux is still worse then if we had a per repo override though14:50
sean-k-mooneyi dont think it conflicts with zuuls design goals but just a lower priortiy nice to have feature14:51
sean-k-mooneyi mean if we are bing strtict about it we dont need extra-config-paths either today but it improves the ux in some cases14:52
corvussean-k-mooney: yep, i get where you're coming from; the main question is how much downstream patches do you want in the repo; zuul was originally designed to support zero for that case, you're willing to accept more.14:55
corvussean-k-mooney: note that by locating your downstream jobs in a separate repo, you can still use/inherit from upstream jobs because you can limit the load objects to only jobs.  that becomes more difficult if you exclude the entire "upstream" config file.14:56
sean-k-mooneycorvus: oh yep i know basicaly if it was not for the restiction on defining the pipelines i would not have raised it14:58
sean-k-mooneycorvus: and ya i know i can filter what gets loaded and how the inheritiance works.14:59
sean-k-mooneytl;dr our ci and qe folks woudl like the upstream devs to work more on downstream ci. we dont want to use jenkisn and want to try and reuse the upstream job from tiple o to test nova downstream with package15:00
sean-k-mooneycorvus: today that is done by defining the jobs and piplien in a config repo but i was trying to see if i could make it feel like working on an upstream job15:01
sean-k-mooneyif i have 2 addtional repos the answer is kind of  with thw 1 repo we hav righ now less so but it can work15:02
clarkbcorvus: https://review.opendev.org/c/zuul/zuul/+/786521 lgtm but I did leave a coupel of notes. I'll work through the stack too15:11
corvussean-k-mooney: ack; to be clear i'm not irc -2ing or anything, just trying to add my perspective / experience and make sure you're aware of all the options and implications :)15:12
corvusclarkb: it does look like the tests are good on that stack (the failures are either expected or random; i don't see any "real" test failures15:16
clarkbcorvus: ya there is a linter catch that I'm trying to understand (its a variable not being used and I'm trying to decide if it is meant to be used or can just be cleaned up)15:18
corvustobiash: if you could look at that stack (despite the test failures) and if it looks okay, i think we can squash and merge soon15:18
clarkbI think it may just need to be cleaned up15:19
corvusclarkb: yeah, my change to that test was pretty mechanistic15:20
clarkbcorvus: "The tests did not catch this because they pass in the format that is expected." I'll admit I used the test you fixed up as a guide :)15:25
clarkbbut also the conditions in isUpdateNeeded :/15:25
clarkbanyway good catch on that15:25
clarkbcorvus: also left a question/comment on https://review.opendev.org/c/zuul/zuul/+/786522 to help better understand this myself15:28
corvusclarkb: good q, replied.  (i did test that yesterday, and my reply is my recollection from that)15:32
*** ykarel has joined #zuul15:35
clarkbok ya that makes sense15:35
sean-k-mooneycorvus: yep apriciate that. baiscaly if im not willing to spend the time to and try to scratch my own itch im not going to be upset if you are going to volenteer to do it either :)15:38
sean-k-mooneyclarkb: we have 3 workable solutions without actully changeing zuul15:38
sean-k-mooneysorry that was for corvus ^15:39
*** rlandy|rover is now known as rlandy|rover|tra15:40
*** rlandy|rover|tra is now known as rlandy|rvr|train15:40
*** hashar has quit IRC15:41
*** ikhan has joined #zuul15:53
tobiashcorvus, clarkb: commented on 78652215:58
corvustobiash: ++16:00
*** ykarel has quit IRC16:01
*** ykarel has joined #zuul16:02
clarkbI think the end result is the same but much clearer in tobiash's suggested state16:02
clarkb(in both cases we would skip right?)16:03
tobiashclarkb: if the repo is not part of the repo state (should not happen anymore with global repo state) we need always an update16:04
clarkbI see so the check for project_repo_state is None would cause an update to happen (I read it as skip in taht case)16:05
tobiashcorvus: there is something I don't yet understand in 78652316:09
tobiashrest of the stack lgtm16:09
openstackgerritAlbin Vass proposed zuul/nodepool master: WIP: Digitalocean driver  https://review.opendev.org/c/zuul/nodepool/+/75955916:09
corvustobiash: your question is actually very similar/related to clarkb's -- in that the key to both is what Repo._reset() does or doesn't do with repo_state16:11
corvustobiash: in 785310 we do a restore on add_project, but otherwise getRepo doesn't do a restore for an existing project16:14
tobiashah yes16:14
corvusi'm totally open to making the repo_state restore more low level (so we do it in reset or getrepo instead of mergeChangess or other high-level methods)16:15
corvusthough i'd suggest if we want to do that, we at least fix up the current changes as-is, then make that change on top (since it looks like we more or less understand the current series and it just needs some tidying up)16:17
*** rlandy|rvr|train is now known as rlandy|rover16:23
*** hamalq has joined #zuul16:28
*** hamalq has quit IRC16:28
*** hamalq has joined #zuul16:29
*** jpena is now known as jpena|off16:31
*** ykarel has quit IRC16:42
clarkbya I think we can fix this stack up but it should be pretty close to mergeable?16:44
clarkbby fixup I mean fix the linting issues and clean up some of the extra lines16:44
corvusya16:46
corvustobiash, clarkb: if we do move repo_state to lower-level, we might be able to drop this https://opendev.org/zuul/zuul/src/branch/master/zuul/executor/server.py#L1108-L111216:47
corvus(because presumably the getRepo call above would have set the state)16:48
*** jcapitao has quit IRC16:55
*** nils has quit IRC16:56
*** VinayJain212 has quit IRC17:15
*** ajitha has joined #zuul17:40
*** vishalmanchanda has quit IRC18:04
openstackgerritJames E. Blair proposed zuul/zuul master: Add a fast-forward test  https://review.opendev.org/c/zuul/zuul/+/78652118:46
openstackgerritJames E. Blair proposed zuul/zuul master: Correct repo_state format in isUpdateNeeded  https://review.opendev.org/c/zuul/zuul/+/78652218:46
openstackgerritJames E. Blair proposed zuul/zuul master: Revert "Revert "Make repo state buildset global""  https://review.opendev.org/c/zuul/zuul/+/78553518:46
openstackgerritJames E. Blair proposed zuul/zuul master: Fix missing repo state restore  https://review.opendev.org/c/zuul/zuul/+/78531018:46
openstackgerritJames E. Blair proposed zuul/zuul master: Keep jobgraphs frozen across reconfiguration  https://review.opendev.org/c/zuul/zuul/+/78553618:46
openstackgerritJames E. Blair proposed zuul/zuul master: Restore repo state in checkoutBranch  https://review.opendev.org/c/zuul/zuul/+/78652318:47
corvusthat's updates from comments; i'm going to squash the 2 that need to go together now18:47
openstackgerritJames E. Blair proposed zuul/zuul master: Fix repo state restore / Keep jobgraphs frozen  https://review.opendev.org/c/zuul/zuul/+/78553618:51
openstackgerritJames E. Blair proposed zuul/zuul master: Restore repo state in checkoutBranch  https://review.opendev.org/c/zuul/zuul/+/78652318:51
corvusI expect that to pass tests and be ready for final review/merge; we'll see what the tests say18:52
clarkbfor the question that just arrived to the zuul-discuss list I think the answer is that job level vars are passed as inventory vars (not passed on the command line). Secrets are passed on the command line. Is that correct?18:54
corvusclarkb: i have a response in progress18:55
clarkbah ok I'll wait to read it then :)18:55
clarkbhttps://opendev.org/zuul/zuul-jobs/src/branch/master/roles/ensure-nodejs/tasks/main.yaml#L26-L27 node_version is the var to set fwiw18:55
clarkband it is set as a default, https://opendev.org/zuul/zuul-jobs/src/branch/master/roles/ensure-nodejs/defaults/main.yaml, which should make it easy to override18:56
corvusyeah, i think they've got it, i think we basically just need to point to which zuul thing to use to set it18:56
clarkbI also think there may be a recent openstack jobs example of fixing this there18:56
corvusi will suggest both the job but also the project level18:56
clarkbcorvus: let me find a link to the openstack chagne as that may be illustrative18:56
corvusclarkb: ok18:56
corvusclarkb: zuul itself does this which i think is super clever: https://opendev.org/zuul/zuul/src/branch/master/.zuul.yaml#L27118:56
*** rlandy|rover is now known as rlandy|rvr|train18:56
clarkbya and openstack does version specific examples18:57
clarkbhttps://opendev.org/openstack/openstack-zuul-jobs/src/branch/master/zuul.d/project-templates.yaml#L2164-L218718:58
clarkbboth may be helpful?18:58
corvusclarkb: thx, replied19:09
openstackgerritGuillaume Chauvel proposed zuul/zuul master: BLOB Restore repo state in checkoutBranch  https://review.opendev.org/c/zuul/zuul/+/78671019:31
guillaumeccorvus, oops19:31
corvusguillaumec: no problem;  i thought about doing that actually :)19:32
guillaumeccorvus, wrong copy/paste when i uploaded a change on top of your during my tests19:32
openstackgerritGuillaume Chauvel proposed zuul/zuul master: Fix FakeGerritRefWatcher and FakeGerritPoller events  https://review.opendev.org/c/zuul/zuul/+/78671119:33
openstackgerritGuillaume Chauvel proposed zuul/zuul master: Fix FakeGerritRefWatcher and FakeGerritPoller events  https://review.opendev.org/c/zuul/zuul/+/78671219:36
corvusguillaumec: thanks! a comment in _poll would be good so we know why it's set up like that.  otherwise i'll probably want to put it back in _run every time i see it :)19:36
*** ajitha has quit IRC19:43
openstackgerritGuillaume Chauvel proposed zuul/zuul master: Fix FakeGerritRefWatcher and FakeGerritPoller events  https://review.opendev.org/c/zuul/zuul/+/78671219:48
*** rlandy|rvr|train is now known as rlandy|rover20:04
openstackgerritAlbin Vass proposed zuul/nodepool master: digitalocean: add image filter config  https://review.opendev.org/c/zuul/nodepool/+/78672320:05
corvusguillaumec: +2 thanks!20:08
clarkbcorvus: that conflicts with your stack do we want to get one or the other in first?20:09
corvusclarkb: looks like it's not a real conflict; i can cherry-pick it20:10
corvusjust a gerrit-conflict :)20:10
clarkbah20:10
corvusand looks like i have test failures, so if you're going to +w it i'd say go for it :)20:11
clarkboh I was just going through your stack again20:12
clarkblet me review guillaumec's20:12
clarkb786712 has been approved20:15
corvusthere are 2 legit test failures that are caused by the change tobiash requested to check for the project_repo_state being None in updateRepo; i'm digging into it.20:15
corvusokay, so there *is* an invocation of merger methods that pass in a repo state that is really a project repo state; so it's possible that in some cases isUpdateNeeded was working as intended20:23
corvusbut i think the right solution to this is still to just have only one kind of repo state as part of the merger api20:23
openstackgerritJames E. Blair proposed zuul/zuul master: Revert "Revert "Make repo state buildset global""  https://review.opendev.org/c/zuul/zuul/+/78553520:28
openstackgerritJames E. Blair proposed zuul/zuul master: Fix repo state restore / Keep jobgraphs frozen  https://review.opendev.org/c/zuul/zuul/+/78553620:28
openstackgerritJames E. Blair proposed zuul/zuul master: Restore repo state in checkoutBranch  https://review.opendev.org/c/zuul/zuul/+/78652320:28
openstackgerritAlbin Vass proposed zuul/nodepool master: digitalocean: add image filter config  https://review.opendev.org/c/zuul/nodepool/+/78672320:30
clarkbcorvus: is https://review.opendev.org/c/zuul/zuul/+/785535/5/zuul/executor/server.py where you had to modify the revert?21:00
corvusclarkb: it's easy to see on a ps4->ps5 diff21:11
corvusclarkb: yes specifically around line 3029 in that file.21:12
clarkbyup with the update task21:12
corvusclarkb: line 1317 and 1319 i modified to match variable names to increase likelihood of future greps being helpful21:12
corvusbut was not required21:12
corvusbasically normalizing on "project_repo_state" as the name of a part of a repo state21:13
clarkb++21:13
*** harrymichal has quit IRC21:19
*** harrymichal has joined #zuul21:19
clarkbcorvus: the diff between https://review.opendev.org/c/zuul/zuul/+/785536/3..7 patchsets 3 and 7 there isn't quite what I expected. It shows the suggested fixups from review but not what I expected from the squashing21:25
clarkbwas this a case of largely noop squashing because 785536 ended up rewriting what was squashed into it prior?21:25
corvusclarkb: yeah, i think the way to look at it is that both patchsets have the other change incorporated in them (one via another commit, one via this one); nothing about it changed, so it doesn't show up in the diff.21:28
corvusan interdiff of the patchsets would probably show the other change21:28
clarkbthe stack lgtm, assuming tests pass I think this is probably ready21:28
clarkbya, the diff and squashing just melted my brain a bit21:29
corvusmeta git21:29
clarkbalso, I'm glad I pushed for the extra test case as I think that helped shake out a bunch of related issues21:34
corvusyep. it's still doing so :)21:36
corvustobiash: i'm looking at https://review.opendev.org/648229 to try to make sure i understand everything21:36
corvustobiash: Repo.reset() does Repo.update() [which is a git fetch] and then Repo._reset() which is basically a very complicated git reset --hard21:38
corvus648229 made it so we skip Repo.reset() on the Merger.updateRepo() call.  but we still call Repo.reset() on Merger.mergeChanges() and Merger.setRepoState().  that means that in the executor, most of the repos are still going to have Repo.reset() called on them (the only high-level method that doesn't call Repo.reset() is Merger.checkoutBranch() -- so basically repos like zuul-jobs)21:41
corvustobiash: so was the benefit of 648229 that it sometimes reduced 2 reset() calls to one?21:41
openstackgerritMerged zuul/zuul master: Fix FakeGerritRefWatcher and FakeGerritPoller events  https://review.opendev.org/c/zuul/zuul/+/78671221:42
corvusclarkb: ^ also if you have any thoughts21:43
clarkbsure, let me finish reviewing this gerrit acl change21:43
corvusi'm kind of struggling with figuring out what it is we're trying to optimize21:43
corvusi *think* what we really want to do is eliminate unecessary fetches, but in all cases we should still do a git reset for any of the 3 high level methods (mergeChanges, checkoutBranch, setRepoState) because that would either clean things up or be a no-op21:45
*** rlandy|rover has quit IRC21:49
avasscorvus: I'm working on getting image builds for digital ocean zuul by bootstrapping from a cloud provider image, installing things in zuul+ansible like a normal job, stopping the instance and snapshotting it. but I realized the instance id is not part of the nodepool data in the inventory21:50
clarkbcorvus: when I was reading the code trying to figure out the original issue fungi and I found the rough set of operations seemed to be: update/fetch if necessary, merge changes, set refs. Reading your comments above and the commit message of that change I think your understanding is what the intent was21:50
clarkbcorvus: basically make that first update/fetch step as cheap as possible21:50
avassis it possible to add data that zookeeper should pass to zuul with the statemachine framework?21:50
avassoh, maybe external_id should just be added to the zk data21:51
clarkbavass: makes sense to have the instance uuid in zk data, but if you can't make that work for some reaosn or miss some other data DO does support the metadata service https://docs.digitalocean.com/products/droplets/how-to/retrieve-droplet-metadata/21:51
avassthere's also a 'host_id' field that is null. not sure what that is for21:51
clarkbyou should be able to get the instances uuid and other info via metadata21:52
avassclarkb: ah yeah that could work21:52
clarkbavass: host_id is the identity of the host platform running the test instance21:52
clarkbavass: its useful for helping providers track down issues if you have jobs that always fail on a host_id21:52
clarkbnot all clouds provide it though21:52
corvusavass: including the external_id in the inventory sounds reasonable21:52
corvusi think that would just be a zuul change, not nodepool21:53
clarkbhost_id == hypervisor id roughly21:53
clarkbbut it may be a k8s node id etc21:54
avassclarkb, corvus: droplet_id is part of the metadata but it could be useful for other providers (or if the metadata service is disabled)21:54
avassso I'll see if I can add it21:54
corvusavass: should just be in executor/server.py21:54
avassoh right that's already stored in zk so it should be enough to add it to the inventory?21:55
corvusya21:56
corvusavass: in fact, just search for host_id to find the spot :)21:57
openstackgerritAlbin Vass proposed zuul/zuul master: Add nodepool.external_id to inventory  https://review.opendev.org/c/zuul/zuul/+/78673821:58
avasscorvus: already did :)21:58
corvusin the merger server, why does updateRepo happen outside of the repo lock?  it can reset the repository, including overwriting branch heads22:05
corvusit seems like if one process is running mergeChanges, it could be writing branch heads that get overwritten by another process handling a cat job22:06
corvus(obvs this only applies to the executor-as-merger, not actual mergers since they are single threads/processes)22:06
*** ikhan has quit IRC22:07
*** ikhan has joined #zuul22:16
*** ikhan has quit IRC22:20
*** sduthil has quit IRC22:21
*** harrymichal has quit IRC23:00
openstackgerritJames E. Blair proposed zuul/zuul master: Clarify merger updates and resets  https://review.opendev.org/c/zuul/zuul/+/78674423:34
corvusclarkb, tobiash: ^ unsure if that passes tests, but that's sort of my thinking on how to make this more clear.  i think it's actually easier to limit repo_state to the high-level methods rather than low-level.23:35
*** tosky has quit IRC23:38

Generated by irclog2html.py 2.17.2 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!