Skip to content

Make it easier for contributors to update Docker images #15332

Closed

Description

@ScottTodd

There is some background context in this Discord discussion.

as with most OSS projects, a push to the Dockerfile on main triggers a rebuild on an ephemeral runner and uses the project token to push to the GitHub package repo without more side-channel auth stuff. The label is based on the branch, so if I push to "test-my-change", then that gets pushed to a label of "test-my-change". Basically, the security permiter ends up defined as who has write access to the repo and is traceable to commits. This seems superior in every way. We could also configure GA to push to another container registry but would need to manage the secrets, etc (and we'd be right back to where we started).

We have ~17 Dockerfiles in the main repo that require authentication (Storage Admin role in the iree-oss GCP project) to update: https://github.com/openxla/iree/tree/main/build_tools/docker. It would be much more convenient for contributors and maintainers if any approved commit could update the images used.

We should see what other projects are doing and modify our setup to be less bespoke.

Possible requirements:

  • Contributors can test that a Dockerfile builds
  • Contributors can test that a Dockerfile does what is expected in a CI workflow
  • Postsubmit uses the latest build of all images from checked in code (our current solution uses a manifest file for this that can get out of sync)

TBD how much scripting/automation is needed for this.

Activity

  1. added
    infrastructure
    on Oct 27, 2023
  2. stellaraccident commented on Oct 27, 2023

    @stellaraccident
    Collaborator

    And then we could just move IREE's docker image building over there.
    I just set up a GH action to update them when the file changes and they push to GH's docker repository.
    It also seems like we should have fewer docker images, but I've not looked closely in quite some time.

  3. self-assigned this
    on Dec 7, 2023
  4. ScottTodd commented on Jul 31, 2024

    @ScottTodd
    MemberAuthor

    As part of moving more jobs from ci.yml go pkgci.yml, I've been chipping away at our use of Docker images. Better to not use Docker at all if we can avoid it.

  5. ScottTodd commented on Aug 8, 2024

    @ScottTodd
    MemberAuthor

    Seems like we could fork https://github.com/nod-ai/base-docker-images into iree-org and iterate from there. Can keep the original repo in nod-ai so existing packages continue to exist and new dockerfiles/images specific to that github org can be developed.

  6. ScottTodd commented on Aug 22, 2024

    @ScottTodd
    MemberAuthor

    Seems like we could fork https://github.com/nod-ai/base-docker-images into iree-org and iterate from there. Can keep the original repo in nod-ai so existing packages continue to exist and new dockerfiles/images specific to that github org can be developed.

    Sent an RFC to fork that repo into iree-org: https://groups.google.com/g/iree-discuss/c/IPLzMsPb5UI

  7. 13 remaining items

  8. ScottTodd commented on Sep 16, 2024

    @ScottTodd
    MemberAuthor

    I'm planning to start migrating build_test_all_bazel to a new dockerfile running on the new Azure build cluster soon. We'll see what issues I run into :)

  9. ScottTodd commented on Sep 23, 2024

    @ScottTodd
    MemberAuthor

    Done!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

infrastructure

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions