Add GitHub action to build and push Docker image#55
Merged
Conversation
|
|
||
| jobs: | ||
| build: | ||
| runs-on: ubuntu-latest |
Contributor
There was a problem hiding this comment.
Pin this to ubuntu-24.04. We've run into quite a few unexpected breakages due to the ubuntu version bumping on us.
| runs-on: ubuntu-latest | ||
|
|
||
| permissions: | ||
| contents: read |
Contributor
There was a problem hiding this comment.
contents: read should be a top level permission. See https://llvm.org/docs/CIBestPractices.html.
| permissions: | ||
| contents: read | ||
| packages: write | ||
| id-token: write |
Contributor
There was a problem hiding this comment.
Why is this needed? We do not use in the workflows in the monorepo https://github.com/llvm/llvm-project/blob/main/.github/workflows/build-ci-container.yml.
| id-token: write | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v5 |
Contributor
There was a problem hiding this comment.
All of these actions need to be hash pinned. See https://llvm.org/docs/CIBestPractices.html.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
To help get the ball rolling with deploying LNT, this adds a GitHub action to build and push images to the GitHub container registry, which is free for public repos. This will push a new image to ghcr.io/llvm-project/llvm-lnt:latest whenever anything is pushed to the main branch.
It also includes a fix for the Dockerfile after the minimum python version was bumped to 3.8 in #48. 3.10 is as high as we can go before we need to upgrade psycopg to 3.x, which in turn requires upgrading sqlalchemy to god knows what. We also need to upgrade psycopg 2.x anyway to get it to build with the newer python bindings.