File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -22,14 +22,14 @@ jobs:
2222 echo "deleting images that start with 'pr-'"
2323 images=$(gh api \
2424 -H "Accept: application/vnd.github+json" \
25- /users/jsturtevant/packages/container/debug-installer/versions \
25+ /users/jsturtevant/packages/container/debug-installer-cache /versions \
2626 --jq '.[] | select(.metadata.container.tags | any(startswith("pr-"))) | .id')
2727
2828 for image in $images; do
2929 # check if image is older than 20hrs
3030 image_age=$(gh api \
3131 -H "Accept: application/vnd.github+json" \
32- /users/jsturtevant/packages/container/debug-installer/versions/$image \
32+ /users/jsturtevant/packages/container/debug-installer-cache /versions/$image \
3333 --jq '.updated_at')
3434
3535 if [[ $(date -d "$image_age" +%s) > $(date -d "24 hours ago" +%s) ]]; then
3939
4040 echo "deleting image $image"
4141 # https://github.com/cli/cli/issues/3937
42- echo -n | gh api --method DELETE -H "Accept: application/vnd.github+json" /users/jsturtevant/packages/container/debug-installer/versions/$image --input -
42+ echo -n | gh api --method DELETE -H "Accept: application/vnd.github+json" /users/jsturtevant/packages/container/debug-installer-cache /versions/$image --input -
4343 done
Original file line number Diff line number Diff line change @@ -3,8 +3,6 @@ name: image
33on :
44 push :
55 tags : ["image-v*"]
6- branches :
7- - main
86 pull_request :
97 branches :
108 - main
@@ -39,12 +37,12 @@ jobs:
3937 - name : build image
4038 run : |
4139 echo $env:IMAGE_VERSION
42- .\build-installer.ps1 -version $env:IMAGE_VERSION
40+ .\build-installer-cache .ps1 -version $env:IMAGE_VERSION
4341 - name : push image
4442 run : |
4543 echo $env:IMAGE_VERSION
4644 $tag=$env:IMAGE_VERSION
47- docker image push ghcr.io/jsturtevant/debug-installer:$tag
45+ docker image push ghcr.io/jsturtevant/debug-installer-cache :$tag
4846 - name : comment on PR
4947 if : ${{ github.event_name == 'pull_request' }}
5048 env :
5351 $comment=@"
5452 Thank you for the contribution :rocket: The debug installer cache image has been published to a temporary repository.
5553
56- You can use it by referencing: ``ghcr.io/jsturtevant/debug-installer:$env:IMAGE_VERSION``.
54+ You can use it by referencing: ``ghcr.io/jsturtevant/debug-installer-cache :$env:IMAGE_VERSION``.
5755
5856 It will be removed in 24 hours.
5957 "@
Original file line number Diff line number Diff line change 11ARG INSTALLER_VERSION="${latest}"
2- FROM ghcr.io/jsturtevant/debug-installer:${INSTALLER_VERSION} as installer
2+ FROM ghcr.io/jsturtevant/debug-installer-cache :${INSTALLER_VERSION} as installer
33
44FROM ghcr.io/marosset/host-process-scratch-image:latest AS runtime
55WORKDIR /apps
Original file line number Diff line number Diff line change 1- param ($version = ' latest' , $image = ' ghcr.io/jsturtevant/debug-installer' )
1+ param ($version = ' latest' , $image = ' ghcr.io/jsturtevant/debug-installer-cache ' )
22
33docker build - t " ${image} :${version} " -f Dockerfile.installer .
You can’t perform that action at this time.
0 commit comments