Compare commits

..

1 Commits

Author SHA1 Message Date
CrazyMax
5ddb01429b ci(e2e): set oci-artifact
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-09-02 17:04:09 +02:00
5 changed files with 7 additions and 43 deletions

View File

@@ -76,7 +76,6 @@ until $(curl --output /dev/null --silent --head --fail "http://$NEXUS_HOST:$NEXU
printf '.'
sleep 5
done
echo "ready!"
echo "::endgroup::"
echo "::group::Change user's password"

View File

@@ -25,15 +25,11 @@ on:
password_secret:
required: false
type: string
cache:
required: false
type: string
default: registry
env:
HARBOR_VERSION: v2.13.2
HARBOR_VERSION: v2.7.0
NEXUS_VERSION: 3.47.1
DISTRIBUTION_VERSION: 3.0.0
DISTRIBUTION_VERSION: 2.8.1
jobs:
run:
@@ -50,7 +46,7 @@ jobs:
buildkit_image: moby/buildkit:buildx-stable-1
-
buildx_version: https://github.com/docker/buildx.git#master
buildkit_image: crazymax/buildkit:s3patch
buildkit_image: moby/buildkit:master
steps:
-
name: Checkout
@@ -60,24 +56,6 @@ jobs:
if: inputs.type == 'local'
run: |
cat ./.github/e2e/${{ inputs.id }}/env >> $GITHUB_ENV
-
name: Set up outputs
uses: actions/github-script@v8
env:
INPUT_SLUG: ${{ env.REGISTRY_SLUG || inputs.slug }}
INPUT_CACHE: ${{ inputs.cache }}
with:
script: |
const inpSlug = core.getInput('slug');
const inpCache = core.getInput('cache');
if (inpCache === 'registry') {
core.exportVariable('CACHE_FROM', `type=registry,ref=${inpSlug}:master`);
core.exportVariable('CACHE_TO', 'type=inline');
} else if (inpCache === 's3') {
const cacheName = inpSlug.replace(/[^a-zA-Z0-9]/g, '-').toLowerCase();
core.exportVariable('CACHE_FROM', `type=s3,region=us-east-2,bucket=buildkit-s3-cache-test,name=${cacheName}`);
core.exportVariable('CACHE_TO', `type=s3,region=us-east-2,bucket=buildkit-s3-cache-test,name=${cacheName},mode=max`);
}
-
name: Set up BuildKit config
run: |
@@ -109,8 +87,6 @@ jobs:
with:
images: ${{ env.REGISTRY_SLUG || inputs.slug }}
tags: |
type=ref,event=branch,enable=${{ matrix.buildx_version == 'latest' && matrix.buildkit_image == 'moby/buildkit:buildx-stable-1' }}
type=ref,event=tag,enable=${{ matrix.buildx_version == 'latest' && matrix.buildkit_image == 'moby/buildkit:buildx-stable-1' }}
type=raw,gh-runid-${{ github.run_id }}
-
name: Set up QEMU
@@ -140,15 +116,11 @@ jobs:
context: ./test
file: ./test/multi.Dockerfile
platforms: linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64,linux/ppc64le,linux/s390x
push: ${{ github.event_name != 'pull_request' }}
outputs: type=image,oci-artifact=true,push=${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: ${{ env.CACHE_FROM }}
cache-to: ${{ env.CACHE_TO }}
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_S3_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_S3_SECRET_ACCESS_KEY }}
AWS_SESSION_TOKEN: ${{ secrets.AWS_S3_SESSION_TOKEN }}
cache-from: type=registry,ref=${{ env.REGISTRY_SLUG || inputs.slug }}:master
cache-to: type=inline
-
name: Inspect image
run: |

View File

@@ -25,11 +25,6 @@ jobs:
name: Distribution
id: distribution
type: local
-
name: Distribution (s3 cache)
id: distribution
type: local
cache: s3
-
name: Docker Hub
registry: ''
@@ -109,5 +104,4 @@ jobs:
slug: ${{ matrix.slug }}
username_secret: ${{ matrix.username_secret }}
password_secret: ${{ matrix.password_secret }}
cache: ${{ matrix.cache || 'registry' }}
secrets: inherit

View File

@@ -131,7 +131,7 @@ jobs:
steps:
-
name: Checkout
uses: actions/checkout@v5
uses: actions/checkout@v4
-
name: Login to Docker Hub
uses: docker/login-action@v3

View File

@@ -1,6 +1,5 @@
# syntax=docker/dockerfile:1
FROM --platform=$BUILDPLATFORM golang:alpine AS build
RUN apk add --no-cache ca-certificates go nodejs rust cargo
ARG TARGETPLATFORM
ARG BUILDPLATFORM