Skip to content

Commit

Permalink
Move builder image to GitHub Container Registry (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
SeanTAllen authored Aug 30, 2023
1 parent dc00c0d commit 2eacef4
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .ci-dockerfiles/builder/build-and-push.bash
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -o nounset
#

DOCKERFILE_DIR="$(dirname "$0")"
NAME="ponylang/pony-sync-helper-ci-builder"
NAME="ghcr.io/ponylang/pony-sync-helper-ci-builder"

# built from x86-64-unknown-linux-builder release tag
FROM_TAG=release
Expand Down
42 changes: 35 additions & 7 deletions .github/workflows/breakage-against-linux-pony-latest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Docker login
run: docker login -u "$DOCKER_USERNAME" -p "$DOCKER_PASSWORD"
env:
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
- name: Login to GitHub Container Registry
# v2.2.0
uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
run: bash .ci-dockerfiles/builder/build-and-push.bash
- name: Send alert on failure
Expand All @@ -29,14 +31,13 @@ jobs:
topic: ${{ github.repository }} scheduled job failure
content: ${{ github.server_url}}/${{ github.repository }}/actions/runs/${{ github.run_id }} failed.


vs-ponyc-main-linux:
name: Verify main against ponyc main on Linux
needs:
- rebuild-builder
runs-on: ubuntu-latest
container:
image: ponylang/pony-sync-helper-ci-builder:latest
image: docker://ghcr.io/ponylang/pony-sync-helper-ci-builder:latest
steps:
- uses: actions/checkout@v3
- name: Test with a recent ponyc from main
Expand All @@ -54,3 +55,30 @@ jobs:
type: stream
topic: ${{ github.repository }} scheduled job failure
content: ${{ github.server_url}}/${{ github.repository }}/actions/runs/${{ github.run_id }} failed.

prune-untagged-images:
needs:
- rebuild-builder

name: Prune untagged images
runs-on: ubuntu-latest
steps:
- name: Prune
# v4.1.1
uses: actions/delete-package-versions@0d39a63126868f5eefaa47169615edd3c0f61e20
with:
package-name: 'pony-sync-helper-ci-builder'
package-type: 'container'
min-versions-to-keep: 1
delete-only-untagged-versions: 'true'
- name: Send alert on failure
if: ${{ failure() }}
uses: zulip/github-actions-zulip/send-message@b62d5a0e48a4d984ea4fce5dd65ba691963d4db4
with:
api-key: ${{ secrets.ZULIP_SCHEDULED_JOB_FAILURE_API_KEY }}
email: ${{ secrets.ZULIP_SCHEDULED_JOB_FAILURE_EMAIL }}
organization-url: 'https://ponylang.zulipchat.com/'
to: notifications
type: stream
topic: ${{ github.repository }} scheduled job failure
content: ${{ github.server_url}}/${{ github.repository }}/actions/runs/${{ github.run_id }} failed.
2 changes: 1 addition & 1 deletion .github/workflows/post-agenda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
name: Post sync agenda to Zulip
runs-on: ubuntu-latest
container:
image: ponylang/pony-sync-helper-ci-builder:latest
image: docker://ghcr.io/ponylang/pony-sync-helper-ci-builder:release
steps:
- uses: actions/checkout@v3
- name: Today's date
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
name: Verify PR builds on Linux with most recent ponyc nightly
runs-on: ubuntu-latest
container:
image: ponylang/pony-sync-helper-ci-builder:latest
image: docker://ghcr.io/ponylang/pony-sync-helper-ci-builder:release
steps:
- uses: actions/checkout@v3
- name: Builds with the most recent ponyc nightly
Expand Down

0 comments on commit 2eacef4

Please sign in to comment.