Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch default base image, adjust other base images #75

Merged
merged 8 commits into from
Jan 14, 2025
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 18 additions & 26 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
pull_request:

env:
DEFAULT_BASE_IMAGE: ubuntu:jammy
DEFAULT_BASE_IMAGE: ubuntu:noble

jobs:
version:
Expand All @@ -18,8 +18,8 @@ jobs:
version-changed: ${{ steps.version-metadata.outputs.changed }}
new-version: ${{ steps.version-metadata.outputs.newVersion }}
steps:
- uses: actions/checkout@v4
- uses: Quantco/ui-actions/version-metadata@v1
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: Quantco/ui-actions/version-metadata@cd71d2a0e30b25569f6d723e57acca83347e58fc # v1.0.18
id: version-metadata
with:
file: Dockerfile
Expand All @@ -43,27 +43,18 @@ jobs:
- debian:bookworm # 12
- debian:bullseye-slim # 11
- debian:bullseye # 11
- ubuntu:plucky # 25.04
- ubuntu:noble # 24.04
- ubuntu:mantic # 23.10
- ubuntu:jammy # 22.04
- ubuntu:focal # 20.04
- nvidia/cuda:12.3.1-base-ubuntu22.04
- nvidia/cuda:12.3.1-base-ubuntu20.04
- nvidia/cuda:12.2.2-base-ubuntu22.04
- nvidia/cuda:12.2.2-base-ubuntu20.04
- nvidia/cuda:12.1.1-base-ubuntu22.04
- nvidia/cuda:12.1.1-base-ubuntu20.04
- nvidia/cuda:11.8.0-base-ubuntu22.04
- nvidia/cuda:11.8.0-base-ubuntu20.04
- nvidia/cuda:11.7.1-base-ubuntu22.04
- nvidia/cuda:11.7.1-base-ubuntu20.04
- nvidia/cuda:11.6.2-base-ubuntu20.04
- nvidia/cuda:11.4.3-base-ubuntu20.04
- nvidia/cuda:11.3.1-base-ubuntu20.04
- nvidia/cuda:11.2.2-base-ubuntu20.04
- nvidia/cuda:12.6.3-base-ubuntu24.04
- nvidia/cuda:12.6.3-base-ubuntu22.04
- nvidia/cuda:12.6.3-base-ubuntu20.04
- nvidia/cuda:11.6.1-base-ubuntu20.04
pavelzw marked this conversation as resolved.
Show resolved Hide resolved
steps:
- name: Checkout source
uses: actions/checkout@v4
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set image variables
id: image-variables
env:
Expand All @@ -78,6 +69,7 @@ jobs:
"20.04": "focal",
"23.10": "mantic",
"24.04": "noble",
"25.05": "plucky"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should that be 25.04?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in #77, thx

}
ubuntu_version_number = base_image.split("-ubuntu")[-1]
base_tag = base_image.split(":")[-1]
Expand All @@ -97,7 +89,7 @@ jobs:
shell: python
- name: Get docker metadata
id: metadata
uses: docker/metadata-action@369eb591f429131d6889c46b94e711f089e6ca96
uses: docker/metadata-action@369eb591f429131d6889c46b94e711f089e6ca96 # v5.6.1
with:
images: |-
ghcr.io/prefix-dev/pixi
Expand All @@ -112,16 +104,16 @@ jobs:
type=semver,pattern={{version}},enable=${{ steps.image-variables.outputs.is-default }},value=${{ needs.version.outputs.new-version }},priority=800
type=semver,pattern={{version}}-${{ steps.image-variables.outputs.tag }},value=${{ needs.version.outputs.new-version }},priority=500
- name: Setup docker buildx
uses: docker/setup-buildx-action@6524bf65af31da8d45b59e8c27de4bd072b392f5
uses: docker/setup-buildx-action@6524bf65af31da8d45b59e8c27de4bd072b392f5 # v3.8.0
- name: Login to GHCR
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build Docker images
id: build
uses: docker/build-push-action@48aba3b46d1b1fec4febb7c5d0c644b249a11355
uses: docker/build-push-action@b32b51a8eda65d6793cd0494a773d4f6bcef32dc # v6.11.0
with:
# provenance: false is needed to avoid unkown/unknown os/arch on ghcr
# see: https://github.com/docker/build-push-action/issues/820
Expand All @@ -132,7 +124,7 @@ jobs:
BASE_IMAGE=${{ matrix.base-image }}
tags: ${{ steps.metadata.outputs.tags }}
labels: ${{ steps.metadata.outputs.labels }}
- uses: actions/upload-artifact@v4
- uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
with:
name: ${{ steps.image-variables.outputs.tag }}
path: ${{ steps.metadata.outputs.bake-file }}
Expand All @@ -152,18 +144,18 @@ jobs:

release:
needs: [version, build]
runs-on: ubuntu-22.04
runs-on: ubuntu-latest
permissions:
contents: write
if: needs.version.outputs.push == 'true'
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Push ${{ needs.version.outputs.new-version }} tag
run: |
git tag ${{ needs.version.outputs.new-version }}
git push origin ${{ needs.version.outputs.new-version }}
- name: Create release
uses: softprops/action-gh-release@v2
uses: softprops/action-gh-release@c95fe1489396fe8a9eb87c0abf8aa5b2ef267fda # v2.2.1
with:
generate_release_notes: true
tag_name: ${{ needs.version.outputs.new-version }}
4 changes: 2 additions & 2 deletions .github/workflows/bump.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
contents: write
pull-requests: write
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Assert latest pixi version is mentioned in README
id: bump
Expand All @@ -27,7 +27,7 @@ jobs:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Create pull request
uses: peter-evans/create-pull-request@67ccf781d68cd99b580ae25a5c18a1cc84ffff1f
uses: peter-evans/create-pull-request@67ccf781d68cd99b580ae25a5c18a1cc84ffff1f # v7.6.0
if: github.ref_name == 'main'
with:
token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
Loading