Monday, 2023-04-24

@jjbeckman:matrix.org> <@clarkb:matrix.org> You may need to use namespaces instead of pods so that the job(s) can manage registry secrets and set that metadata on the image pull spec02:48
If anyone could point me to how one could use an image registry other than docker.io, it would be greatly appreciated. Still haven't been able to figure how to do so with Nexus.
@iwienand:matrix.org> <@gerrit:opendev.org> Clark Boylan proposed: [zuul/zuul-jobs] 881277: Use full image url in container buildx path  https://review.opendev.org/c/zuul/zuul-jobs/+/88127704:45
I've dropped some comments but I feel like this is the wrong name ... if the buildset registry has a tag ```quay.io/foo/bar:latest```, any pulls like "docker pull quay.io/foo/bar:latest" in jobs later on are going to split that up into "ask quay.io for /foo/bar:latest", where after using ```use-buildset-registry```, "ask quay.io" equates to "ask the buildset registry for", since we set the buildset registry up as a mirror. i.e. the buildset registry is going to get asks for ```foo/bar:latest``` which it won't see, because it only has ```quay.io/foo/bar:latest```?
@iwienand:matrix.org> <@gerrit:opendev.org> Clark Boylan proposed: [zuul/zuul-jobs] 881277: Use full image url in container buildx path  https://review.opendev.org/c/zuul/zuul-jobs/+/88127704:45
* I've dropped some comments but I feel like this is the wrong name ... if the buildset registry has a tag `quay.io/foo/bar:latest`, any pulls like "docker pull quay.io/foo/bar:latest" in jobs later on are going to split that up into "ask quay.io for foo/bar:latest", where after using `use-buildset-registry`, "ask quay.io" equates to "ask the buildset registry for", since we set the buildset registry up as a mirror. i.e. the buildset registry is going to get asks for `foo/bar:latest` which it won't see, because it only has `quay.io/foo/bar:latest`?
@iwienand:matrix.org * I've dropped some comments but I feel like this is the wrong name ... if the buildset registry has a tag `quay.io/foo/bar:latest`, any pulls like "docker pull quay.io/foo/bar:latest" in jobs later on are going to split that up into "ask quay.io for foo/bar:latest", where after using `use-buildset-registry`, "ask quay.io" equates to "ask the buildset registry for", since we set the buildset registry up as a mirror.  i.e. the buildset registry is going to get asked for `foo/bar:latest` which it won't see, because it only has `quay.io/foo/bar:latest`?04:46
@clarkb:matrix.orgianw: the reason for the prefix is that we may have different colliding images for different registries04:51
@clarkb:matrix.orgIt hasn't really been an issue until now but I think the intention was always to support that?04:51
@clarkb:matrix.org> <@jjbeckman:matrix.org> If anyone could point me to how one could use an image registry other than docker.io, it would be greatly appreciated. Still haven't been able to figure how to do so with Nexus.04:52
Have you tried using namespace resources instead? Then you should be able to create image resources in the job that set credentials for the registry.
@iwienand:matrix.org> <@clarkb:matrix.org> ianw: the reason for the prefix is that we may have different colliding images for different registries05:13
Yeah, I agree, but I'm not 100% that we are setup so that with a buildset registry, ```docker pull quay.io/foo/bar``` actually asks for ```buildset-registry:5000/quay.io/foo/bar```?
@iwienand:matrix.orghttps://opendev.org/zuul/zuul-jobs/src/commit/b7f983c6210bf6d57a343c67d6b87168a305c3e4/roles/use-buildset-registry/library/modify_registries_conf.py#L6305:13
@clarkb:matrix.orgIt looks like that does add the buildset registry with the prefix as the first location to check them the actual location (via raw prefix) otherwise05:23
@iwienand:matrix.orgyeah, ok, i may have confused myself by looking too hard at it05:58
@jjbeckman:matrix.org> <@clarkb:matrix.org> Have you tried using namespace resources instead? Then you should be able to create image resources in the job that set credentials for the registry.06:38
Thank you for the suggestion. No, I have not tried namespaces yet. I've configured `type: namespace` in `nodepool.yaml`, and have observed that Zuul creates namespaces which contain no pods. Other than that, I have yet to figure out what the intended use case is. Does documentation regarding how to use "type: namespace" instead of `type: pod`, which I am able to use successfully, other than the fact that there is seemingly no way to authenticate with a private registry.
@clarkb:matrix.org> <@jjbeckman:matrix.org> Thank you for the suggestion. No, I have not tried namespaces yet. I've configured `type: namespace` in `nodepool.yaml`, and have observed that Zuul creates namespaces which contain no pods. Other than that, I have yet to figure out what the intended use case is. Does documentation regarding how to use "type: namespace" instead of `type: pod`, which I am able to use successfully, other than the fact that there is seemingly no way to authenticate with a private registry.15:40
When you use the namespace resources instead of pod resources you are given credentials for managing a k8s namespace. This means you can create pods in that namespace how you like. I believe this includes creating image definitions with credetnials to authenticate to your registry. As I mentioned before I don't think there is any mechanism currently to have the pod resource provider configure registry authentication. But I suspect that you can work around this using namespaces
@clarkb:matrix.orgcorvus: I think https://review.opendev.org/c/zuul/zuul-jobs/+/881277 is the next step for nodepool image builds + quay. Please look it over carefully though as the switch to localhost in testing sort of papers over a limitation here. But one that has always existed I believe, just more apparent now without the docker default registry being used15:41
@jim:acmegating.comClark: +2 with comment on that20:39
@clarkb:matrix.orgcorvus: cool I think we can probably approve that now as a workaround and figure out making this better once the quay transition is done?20:45
@jim:acmegating.comClark: wfm20:46
@clarkb:matrix.orgshould I approve it or do you want to do that?20:48
@jim:acmegating.comdone20:49
-@gerrit:opendev.org- Zuul merged on behalf of Clark Boylan: [zuul/zuul-jobs] 881277: Use full image url in container buildx path https://review.opendev.org/c/zuul/zuul-jobs/+/88127721:01
@clarkb:matrix.orgcorvus: I would expect rechecking the nodepool change sto be happy now?21:02
@jim:acmegating.comagreed; recheck issued21:09
@clarkb:matrix.orgI think it worked. Stilla couple of jobs to run though21:51
-@gerrit:opendev.org- James E. Blair https://matrix.to/#/@jim:acmegating.com proposed: [zuul/zuul] 881408: Improve FrozenJob.isEqual https://review.opendev.org/c/zuul/zuul/+/88140822:00
@clarkb:matrix.orgThe nodepool chnage got a +122:16
@jim:acmegating.comrechecking the operator change 881245. i think it was the same issue?22:22
@clarkb:matrix.orgwouldn't surprise me22:23
@clarkb:matrix.orgbut not sure I looked at that one22:23
@jim:acmegating.comoh no it was the dockerfile path one; but that merged22:24
@jim:acmegating.comso let's see if it goes green now, if so, i think we're good22:24
@jim:acmegating.comClark: https://review.opendev.org/q/hashtag:quay22:25
@clarkb:matrix.orgyup I should hve a +2 on all of them22:26
@jim:acmegating.comyes you do -- sorry was just pasting that since i just added the hashtag for easy dashboarding :)22:26
@clarkb:matrix.orgcorvus: if you have time for https://review.opendev.org/c/opendev/system-config/+/881285 and its depends on (the depends on is more relevant to this channel) that would be good too. This is the opendev side of things and I updated the ensure-quay role in response22:27
@jim:acmegating.comClark: sure -- +2 on the jobs change, and some comments on the opendev one -- but i wonder if we want to think about putting the ensure-quay role in the opendev container base-jobs so that it's automatic.  we would need to add a condition so it only ran on quay.io images...22:35
@clarkb:matrix.orgI think we could do that too22:36
@jim:acmegating.comotherwise we might end up copying that pre playbook to a lot of repos22:36
@clarkb:matrix.orgI havne't been able to manually test the ensure-quay role yet after the refactor too. I can probably do that tomorrow (i did test the previous edition manually)22:36
@jim:acmegating.comwe could check for quay.io inside the loop, but then we might burn a lot of ansible tasks if it's unused... we could put a top-level boolean job variable to switch it on or of...22:37
@jim:acmegating.comnot sure the best approach22:37
@clarkb:matrix.orgI'll think about it. Responded to your comments on the system-config change22:38
-@gerrit:opendev.org- James E. Blair https://matrix.to/#/@jim:acmegating.com proposed: [zuul/zuul] 880874: WIP: Add ZK load testing script https://review.opendev.org/c/zuul/zuul/+/88087423:00
-@gerrit:opendev.org- Zuul merged on behalf of Clark Boylan: [zuul/zuul-jobs] 877834: Add ensure-quay-repo role https://review.opendev.org/c/zuul/zuul-jobs/+/87783423:08
@clarkb:matrix.orgcool I'll work on testing ^ tomorrow and worst case I can push updates23:15
@clarkb:matrix.orgnothing is using it yet23:15
-@gerrit:opendev.org- James E. Blair https://matrix.to/#/@jim:acmegating.com proposed: [zuul/zuul-operator] 881245: Publish container images to quay.io https://review.opendev.org/c/zuul/zuul-operator/+/88124523:23
@jim:acmegating.comClark: ^ okay i think we're past container image issues and on to bitrot issues for the operator23:23
@clarkb:matrix.orglooking23:24

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