mirror of
https://github.com/floci-io/floci.git
synced 2026-11-25 06:47:41 -05:00
Bumps the actions-minor-patch group with 3 updates: [actions/upload-artifact](https://github.com/actions/upload-artifact), [actions/download-artifact](https://github.com/actions/download-artifact) and [actions/setup-node](https://github.com/actions/setup-node). Updates `actions/upload-artifact` from 7.0.1 to 7.0.2 - [Release notes](https://github.com/actions/upload-artifact/releases) - [Commits](https://github.com/actions/upload-artifact/compare/043fb46d1a93c77aae656e7c1c64a875d1fc6a0a...cf430e030ddbb5b0abf93d22962f4752f3646cd9) Updates `actions/download-artifact` from 8.0.1 to 8.0.2 - [Release notes](https://github.com/actions/download-artifact/releases) - [Commits](https://github.com/actions/download-artifact/compare/3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c...9000827ccba6bdab643e8b6fd33ac0654aef8333) Updates `actions/setup-node` from 7.0.0 to 7.1.0 - [Release notes](https://github.com/actions/setup-node/releases) - [Commits](https://github.com/actions/setup-node/compare/820762786026740c76f36085b0efc47a31fe5020...949feb2413d6458794dcd2491c4babbbce0c15c1) --- updated-dependencies: - dependency-name: actions/upload-artifact dependency-version: 7.0.2 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: actions-minor-patch - dependency-name: actions/download-artifact dependency-version: 8.0.2 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: actions-minor-patch - dependency-name: actions/setup-node dependency-version: 7.1.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: actions-minor-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
479 lines
20 KiB
YAML
479 lines
20 KiB
YAML
name: Build Floci Images
|
|
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
source-ref:
|
|
description: Floci branch, tag, or commit to publish
|
|
required: true
|
|
type: string
|
|
image:
|
|
description: OCI image repository including registry host (for example, ghcr.io/org/floci), without a tag or digest
|
|
required: true
|
|
type: string
|
|
publish-native:
|
|
description: Also publish native and native compatibility images
|
|
required: false
|
|
type: boolean
|
|
default: false
|
|
secrets:
|
|
REGISTRY_USERNAME:
|
|
description: Username for a registry other than GHCR
|
|
required: false
|
|
REGISTRY_TOKEN:
|
|
description: Token for a registry other than GHCR
|
|
required: false
|
|
outputs:
|
|
source-sha:
|
|
description: Full source revision used for all images
|
|
value: ${{ jobs.prepare.outputs.source-sha }}
|
|
image-tag:
|
|
description: Timestamped source revision tag used for all images
|
|
value: ${{ jobs.prepare.outputs.image-tag }}
|
|
image-ref:
|
|
description: Commit-tagged default JVM image reference
|
|
value: ${{ jobs.publish.outputs.jvm-ref }}
|
|
image-digest-ref:
|
|
description: Immutable default JVM image reference
|
|
value: ${{ jobs.publish.outputs.jvm-digest-ref }}
|
|
jvm-ref:
|
|
description: Commit-tagged JVM image reference
|
|
value: ${{ jobs.publish.outputs.jvm-ref }}
|
|
jvm-digest-ref:
|
|
description: Immutable JVM image reference
|
|
value: ${{ jobs.publish.outputs.jvm-digest-ref }}
|
|
native-ref:
|
|
description: Commit-tagged native image reference when publish-native is true
|
|
value: ${{ jobs.publish.outputs.native-ref }}
|
|
native-digest-ref:
|
|
description: Immutable native image reference when publish-native is true
|
|
value: ${{ jobs.publish.outputs.native-digest-ref }}
|
|
compat-ref:
|
|
description: Commit-tagged native compatibility image reference when publish-native is true
|
|
value: ${{ jobs.publish.outputs.compat-ref }}
|
|
compat-digest-ref:
|
|
description: Immutable native compatibility image reference when publish-native is true
|
|
value: ${{ jobs.publish.outputs.compat-digest-ref }}
|
|
|
|
permissions: {}
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.repository }}-${{ inputs.source-ref }}-${{ inputs.image }}-${{ inputs.publish-native }}
|
|
cancel-in-progress: false
|
|
|
|
jobs:
|
|
prepare:
|
|
name: Resolve source and image
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
contents: read
|
|
outputs:
|
|
image: ${{ steps.image.outputs.image }}
|
|
registry: ${{ steps.image.outputs.registry }}
|
|
source-sha: ${{ steps.source.outputs.sha }}
|
|
image-tag: ${{ steps.source.outputs.image-tag }}
|
|
product-version: ${{ steps.source.outputs.product-version }}
|
|
|
|
steps:
|
|
- name: Validate image repository
|
|
id: image
|
|
shell: bash
|
|
env:
|
|
IMAGE: ${{ inputs.image }}
|
|
REPOSITORY_OWNER: ${{ github.repository_owner }}
|
|
run: |
|
|
owner="${REPOSITORY_OWNER,,}"
|
|
image="$IMAGE"
|
|
|
|
if [[ "$image" != */* ]]; then
|
|
echo "image must include a registry host and repository path." >&2
|
|
exit 1
|
|
fi
|
|
|
|
registry="${image%%/*}"
|
|
repository="${image#*/}"
|
|
registry_pattern='^([a-z0-9]([a-z0-9.-]*[a-z0-9])?)(:[0-9]{1,5})?$'
|
|
component='[a-z0-9]+([._-][a-z0-9]+)*'
|
|
repository_pattern="^${component}(/${component})*$"
|
|
|
|
if [[ "$registry" != "${registry,,}" || ! "$registry" =~ $registry_pattern ]]; then
|
|
echo "image registry must be a lowercase host with an optional port." >&2
|
|
exit 1
|
|
fi
|
|
if [[ "$registry" == *..* || "$registry" == *.-* || "$registry" == *-.* ]]; then
|
|
echo "image registry contains an invalid host separator." >&2
|
|
exit 1
|
|
fi
|
|
if [[ "$registry" == *:* ]]; then
|
|
port="${registry##*:}"
|
|
if (( 10#$port < 1 || 10#$port > 65535 )); then
|
|
echo "image registry port must be between 1 and 65535." >&2
|
|
exit 1
|
|
fi
|
|
fi
|
|
if [[ "$repository" != "${repository,,}" || ! "$repository" =~ $repository_pattern ]]; then
|
|
echo "image repository must be a lowercase path without a tag or digest." >&2
|
|
exit 1
|
|
fi
|
|
if [[ "$registry" == "ghcr.io" && "$repository" != "$owner/"* ]]; then
|
|
echo "GITHUB_TOKEN publication requires a GHCR repository under $owner/." >&2
|
|
exit 1
|
|
fi
|
|
|
|
echo "registry=$registry" >> "$GITHUB_OUTPUT"
|
|
echo "image=$image" >> "$GITHUB_OUTPUT"
|
|
|
|
- name: Validate external registry credentials
|
|
if: steps.image.outputs.registry != 'ghcr.io'
|
|
shell: bash
|
|
env:
|
|
REGISTRY_USERNAME: ${{ secrets.REGISTRY_USERNAME }}
|
|
REGISTRY_TOKEN: ${{ secrets.REGISTRY_TOKEN }}
|
|
run: |
|
|
if [[ -z "$REGISTRY_USERNAME" || -z "$REGISTRY_TOKEN" ]]; then
|
|
echo "External registries require REGISTRY_USERNAME and REGISTRY_TOKEN." >&2
|
|
exit 1
|
|
fi
|
|
|
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
persist-credentials: false
|
|
ref: ${{ inputs.source-ref }}
|
|
|
|
- name: Resolve source revision
|
|
id: source
|
|
shell: bash
|
|
run: |
|
|
source_sha="$(git rev-parse HEAD)"
|
|
source_short="${source_sha:0:8}"
|
|
timestamp="$(date -u +'%Y%m%d.%H%M%S')"
|
|
product_version="$(./mvnw -q -DforceStdout help:evaluate -Dexpression=project.version)"
|
|
|
|
if [[ -z "$product_version" ]]; then
|
|
echo "Could not resolve the Floci project version." >&2
|
|
exit 1
|
|
fi
|
|
|
|
echo "sha=$source_sha" >> "$GITHUB_OUTPUT"
|
|
echo "image-tag=$timestamp.$source_short" >> "$GITHUB_OUTPUT"
|
|
echo "product-version=$product_version" >> "$GITHUB_OUTPUT"
|
|
|
|
build-native-amd64:
|
|
name: Build native artifact (amd64)
|
|
if: inputs.publish-native
|
|
needs: prepare
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 45
|
|
permissions:
|
|
contents: read
|
|
|
|
steps:
|
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
persist-credentials: false
|
|
ref: ${{ needs.prepare.outputs.source-sha }}
|
|
|
|
- uses: graalvm/setup-graalvm@27b360dbb857524eaf0b4c4cef364d38e5b4f173 # v1
|
|
with:
|
|
java-version: '25'
|
|
distribution: mandrel
|
|
cache: maven
|
|
github-token: ${{ github.token }}
|
|
|
|
- name: Build native executable
|
|
# Quarkus 3.39 switches on -H:+AOTSingleCallsiteInline for Mandrel 25.0.4+. The generated
|
|
# REST invokers for AwsQueryController.dispatch and AwsJson11Controller.handle are each the
|
|
# single call site of a very large method; inlined, the method outgrows the aarch64
|
|
# conditional-branch range and the build dies with BranchTargetOutOfBoundsException.
|
|
# The flag only exists on Mandrel, so it is passed here rather than in application.yml.
|
|
run: ./mvnw clean package -Dnative -DskipTests -B -Dquarkus.native.additional-build-args-append="-march=x86-64-v2,-H:-AOTSingleCallsiteInline"
|
|
|
|
- uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
|
|
with:
|
|
name: floci-native-amd64-${{ needs.prepare.outputs.image-tag }}
|
|
path: |
|
|
target/*-runner
|
|
target/*.properties
|
|
target/*.so
|
|
if-no-files-found: error
|
|
retention-days: 1
|
|
|
|
build-native-arm64:
|
|
name: Build native artifact (arm64)
|
|
if: inputs.publish-native
|
|
needs: prepare
|
|
runs-on: ubuntu-24.04-arm
|
|
timeout-minutes: 45
|
|
permissions:
|
|
contents: read
|
|
|
|
steps:
|
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
persist-credentials: false
|
|
ref: ${{ needs.prepare.outputs.source-sha }}
|
|
|
|
- uses: graalvm/setup-graalvm@27b360dbb857524eaf0b4c4cef364d38e5b4f173 # v1
|
|
with:
|
|
java-version: '25'
|
|
distribution: mandrel
|
|
cache: maven
|
|
github-token: ${{ github.token }}
|
|
|
|
- name: Build native executable
|
|
# Quarkus 3.39 switches on -H:+AOTSingleCallsiteInline for Mandrel 25.0.4+. The generated
|
|
# REST invokers for AwsQueryController.dispatch and AwsJson11Controller.handle are each the
|
|
# single call site of a very large method; inlined, the method outgrows the aarch64
|
|
# conditional-branch range and the build dies with BranchTargetOutOfBoundsException.
|
|
# The flag only exists on Mandrel, so it is passed here rather than in application.yml.
|
|
run: ./mvnw clean package -Dnative -DskipTests -B -Dquarkus.native.additional-build-args-append="-H:-AOTSingleCallsiteInline"
|
|
|
|
- uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
|
|
with:
|
|
name: floci-native-arm64-${{ needs.prepare.outputs.image-tag }}
|
|
path: |
|
|
target/*-runner
|
|
target/*.properties
|
|
target/*.so
|
|
if-no-files-found: error
|
|
retention-days: 1
|
|
|
|
publish:
|
|
name: Publish images
|
|
needs: [prepare, build-native-amd64, build-native-arm64]
|
|
if: >-
|
|
${{
|
|
always() &&
|
|
needs.prepare.result == 'success' &&
|
|
(!inputs.publish-native ||
|
|
(needs.build-native-amd64.result == 'success' &&
|
|
needs.build-native-arm64.result == 'success'))
|
|
}}
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 45
|
|
permissions:
|
|
contents: read
|
|
packages: write
|
|
outputs:
|
|
compat-ref: ${{ steps.provenance.outputs.compat-ref }}
|
|
compat-digest-ref: ${{ steps.provenance.outputs.compat-digest-ref }}
|
|
jvm-ref: ${{ steps.provenance.outputs.jvm-ref }}
|
|
jvm-digest-ref: ${{ steps.provenance.outputs.jvm-digest-ref }}
|
|
native-ref: ${{ steps.provenance.outputs.native-ref }}
|
|
native-digest-ref: ${{ steps.provenance.outputs.native-digest-ref }}
|
|
|
|
steps:
|
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
persist-credentials: false
|
|
ref: ${{ needs.prepare.outputs.source-sha }}
|
|
|
|
- uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
|
|
if: inputs.publish-native
|
|
with:
|
|
name: floci-native-amd64-${{ needs.prepare.outputs.image-tag }}
|
|
path: native/amd64/
|
|
|
|
- uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
|
|
if: inputs.publish-native
|
|
with:
|
|
name: floci-native-arm64-${{ needs.prepare.outputs.image-tag }}
|
|
path: native/arm64/
|
|
|
|
- name: Make native binaries executable
|
|
if: inputs.publish-native
|
|
run: chmod +x native/amd64/*-runner native/arm64/*-runner
|
|
|
|
- name: Set build metadata
|
|
id: metadata
|
|
shell: bash
|
|
run: |
|
|
echo "created=$(date -u +'%Y-%m-%dT%H:%M:%SZ')" >> "$GITHUB_OUTPUT"
|
|
echo "source-date-epoch=$(git log -1 --pretty=%ct)" >> "$GITHUB_OUTPUT"
|
|
|
|
- uses: docker/setup-buildx-action@f87e5991a6d7451dcb8d9637bfbc97413f497069 # v4.4.1
|
|
|
|
- name: Log in to GitHub Container Registry
|
|
if: needs.prepare.outputs.registry == 'ghcr.io'
|
|
uses: docker/login-action@dbcb813823bdd20940b903addbd779551569679f # v4.6.0
|
|
with:
|
|
registry: ghcr.io
|
|
username: ${{ github.actor }}
|
|
password: ${{ github.token }}
|
|
|
|
- name: Log in to configured registry
|
|
if: needs.prepare.outputs.registry != 'ghcr.io'
|
|
uses: docker/login-action@dbcb813823bdd20940b903addbd779551569679f # v4.6.0
|
|
with:
|
|
registry: ${{ needs.prepare.outputs.registry }}
|
|
username: ${{ secrets.REGISTRY_USERNAME }}
|
|
password: ${{ secrets.REGISTRY_TOKEN }}
|
|
|
|
- name: Build and publish JVM image
|
|
id: jvm
|
|
uses: docker/build-push-action@c3c9e263c25d99ce0380d002d59b67737d91b0dc # v7.4.0
|
|
env:
|
|
SOURCE_DATE_EPOCH: ${{ steps.metadata.outputs.source-date-epoch }}
|
|
with:
|
|
context: .
|
|
file: docker/Dockerfile
|
|
platforms: linux/amd64,linux/arm64
|
|
push: true
|
|
tags: ${{ needs.prepare.outputs.image }}:${{ needs.prepare.outputs.image-tag }}
|
|
build-args: |
|
|
VERSION=${{ needs.prepare.outputs.product-version }}
|
|
labels: |
|
|
org.opencontainers.image.version=${{ needs.prepare.outputs.product-version }}
|
|
org.opencontainers.image.revision=${{ needs.prepare.outputs.source-sha }}
|
|
org.opencontainers.image.vcs-ref=${{ needs.prepare.outputs.source-sha }}
|
|
org.opencontainers.image.created=${{ steps.metadata.outputs.created }}
|
|
org.opencontainers.image.source=${{ github.server_url }}/${{ github.repository }}
|
|
version=${{ needs.prepare.outputs.product-version }}
|
|
build-date=${{ steps.metadata.outputs.created }}
|
|
vcs-ref=${{ needs.prepare.outputs.source-sha }}
|
|
cache-from: type=gha,scope=floci-jvm
|
|
cache-to: type=gha,scope=floci-jvm,mode=max
|
|
|
|
- name: Build and publish native image
|
|
id: native
|
|
if: inputs.publish-native
|
|
uses: docker/build-push-action@c3c9e263c25d99ce0380d002d59b67737d91b0dc # v7.4.0
|
|
env:
|
|
SOURCE_DATE_EPOCH: ${{ steps.metadata.outputs.source-date-epoch }}
|
|
with:
|
|
context: .
|
|
file: docker/Dockerfile.native-package
|
|
platforms: linux/amd64,linux/arm64
|
|
push: true
|
|
tags: ${{ needs.prepare.outputs.image }}:${{ needs.prepare.outputs.image-tag }}-native
|
|
build-args: |
|
|
VERSION=${{ needs.prepare.outputs.product-version }}
|
|
labels: |
|
|
org.opencontainers.image.version=${{ needs.prepare.outputs.product-version }}
|
|
org.opencontainers.image.revision=${{ needs.prepare.outputs.source-sha }}
|
|
org.opencontainers.image.vcs-ref=${{ needs.prepare.outputs.source-sha }}
|
|
org.opencontainers.image.created=${{ steps.metadata.outputs.created }}
|
|
org.opencontainers.image.source=${{ github.server_url }}/${{ github.repository }}
|
|
version=${{ needs.prepare.outputs.product-version }}
|
|
build-date=${{ steps.metadata.outputs.created }}
|
|
vcs-ref=${{ needs.prepare.outputs.source-sha }}
|
|
cache-from: type=gha,scope=floci-native
|
|
cache-to: type=gha,scope=floci-native,mode=max
|
|
|
|
- name: Build and publish compat image
|
|
id: compat
|
|
if: inputs.publish-native
|
|
uses: docker/build-push-action@c3c9e263c25d99ce0380d002d59b67737d91b0dc # v7.4.0
|
|
env:
|
|
SOURCE_DATE_EPOCH: ${{ steps.metadata.outputs.source-date-epoch }}
|
|
with:
|
|
context: .
|
|
file: docker/Dockerfile.compat
|
|
platforms: linux/amd64,linux/arm64
|
|
push: true
|
|
tags: ${{ needs.prepare.outputs.image }}:${{ needs.prepare.outputs.image-tag }}-native-compat
|
|
build-args: |
|
|
VERSION=${{ needs.prepare.outputs.product-version }}
|
|
BASE_IMAGE=${{ needs.prepare.outputs.image }}@${{ steps.native.outputs.digest }}
|
|
labels: |
|
|
org.opencontainers.image.version=${{ needs.prepare.outputs.product-version }}
|
|
org.opencontainers.image.revision=${{ needs.prepare.outputs.source-sha }}
|
|
org.opencontainers.image.vcs-ref=${{ needs.prepare.outputs.source-sha }}
|
|
org.opencontainers.image.created=${{ steps.metadata.outputs.created }}
|
|
org.opencontainers.image.source=${{ github.server_url }}/${{ github.repository }}
|
|
version=${{ needs.prepare.outputs.product-version }}
|
|
build-date=${{ steps.metadata.outputs.created }}
|
|
vcs-ref=${{ needs.prepare.outputs.source-sha }}
|
|
cache-from: type=gha,scope=floci-compat
|
|
cache-to: type=gha,scope=floci-compat,mode=max
|
|
|
|
- name: Record image provenance
|
|
id: provenance
|
|
env:
|
|
COMPAT_DIGEST: ${{ steps.compat.outputs.digest }}
|
|
CREATED: ${{ steps.metadata.outputs.created }}
|
|
IMAGE: ${{ needs.prepare.outputs.image }}
|
|
IMAGE_TAG: ${{ needs.prepare.outputs.image-tag }}
|
|
JVM_DIGEST: ${{ steps.jvm.outputs.digest }}
|
|
NATIVE_DIGEST: ${{ steps.native.outputs.digest }}
|
|
PRODUCT_VERSION: ${{ needs.prepare.outputs.product-version }}
|
|
PUBLISH_NATIVE: ${{ inputs.publish-native }}
|
|
REPOSITORY: ${{ github.repository }}
|
|
REQUESTED_SOURCE_REF: ${{ inputs.source-ref }}
|
|
RUN_ATTEMPT: ${{ github.run_attempt }}
|
|
RUN_ID: ${{ github.run_id }}
|
|
SERVER_URL: ${{ github.server_url }}
|
|
SOURCE_SHA: ${{ needs.prepare.outputs.source-sha }}
|
|
shell: bash
|
|
run: |
|
|
jvm_ref="$IMAGE:$IMAGE_TAG"
|
|
jvm_digest_ref="$IMAGE@$JVM_DIGEST"
|
|
native_ref="$IMAGE:$IMAGE_TAG-native"
|
|
compat_ref="$IMAGE:$IMAGE_TAG-native-compat"
|
|
native_digest_ref="$IMAGE@$NATIVE_DIGEST"
|
|
compat_digest_ref="$IMAGE@$COMPAT_DIGEST"
|
|
run_url="$SERVER_URL/$REPOSITORY/actions/runs/$RUN_ID/attempts/$RUN_ATTEMPT"
|
|
|
|
jq -n \
|
|
--arg sourceSha "$SOURCE_SHA" \
|
|
--arg requestedSourceRef "$REQUESTED_SOURCE_REF" \
|
|
--arg created "$CREATED" \
|
|
--arg imageTag "$IMAGE_TAG" \
|
|
--arg productVersion "$PRODUCT_VERSION" \
|
|
--arg repository "$REPOSITORY" \
|
|
--arg runId "$RUN_ID" \
|
|
--arg runAttempt "$RUN_ATTEMPT" \
|
|
--arg runUrl "$run_url" \
|
|
--arg jvmRef "$jvm_ref" \
|
|
--arg jvmDigest "$JVM_DIGEST" \
|
|
--arg jvmDigestRef "$jvm_digest_ref" \
|
|
'{source: {sha: $sourceSha, requestedRef: $requestedSourceRef, repository: $repository}, workflow: {runId: $runId, attempt: $runAttempt, url: $runUrl}, created: $created, imageTag: $imageTag, productVersion: $productVersion, images: {jvm: {ref: $jvmRef, digest: $jvmDigest, digestRef: $jvmDigestRef, dockerfile: "docker/Dockerfile"}}, platforms: ["linux/amd64", "linux/arm64"]}' \
|
|
> floci-image-provenance.json
|
|
|
|
if [[ "$PUBLISH_NATIVE" == "true" ]]; then
|
|
jq \
|
|
--arg nativeRef "$native_ref" \
|
|
--arg nativeDigest "$NATIVE_DIGEST" \
|
|
--arg nativeDigestRef "$native_digest_ref" \
|
|
--arg compatRef "$compat_ref" \
|
|
--arg compatDigest "$COMPAT_DIGEST" \
|
|
--arg compatDigestRef "$compat_digest_ref" \
|
|
'.images.native = {ref: $nativeRef, digest: $nativeDigest, digestRef: $nativeDigestRef, dockerfile: "docker/Dockerfile.native-package"}
|
|
| .images.compat = {ref: $compatRef, digest: $compatDigest, digestRef: $compatDigestRef, dockerfile: "docker/Dockerfile.compat", base: $nativeDigestRef}' \
|
|
floci-image-provenance.json > floci-image-provenance.tmp
|
|
mv floci-image-provenance.tmp floci-image-provenance.json
|
|
fi
|
|
|
|
{
|
|
echo "jvm-ref=$jvm_ref"
|
|
echo "jvm-digest-ref=$jvm_digest_ref"
|
|
if [[ "$PUBLISH_NATIVE" == "true" ]]; then
|
|
echo "native-ref=$native_ref"
|
|
echo "native-digest-ref=$native_digest_ref"
|
|
echo "compat-ref=$compat_ref"
|
|
echo "compat-digest-ref=$compat_digest_ref"
|
|
fi
|
|
} >> "$GITHUB_OUTPUT"
|
|
|
|
{
|
|
echo "## Floci images"
|
|
echo
|
|
echo "Source: \`$SOURCE_SHA\`"
|
|
echo "Product version: \`$PRODUCT_VERSION\`"
|
|
echo
|
|
echo "| Image tag | Immutable digest reference |"
|
|
echo "| --- | --- |"
|
|
echo "| \`$jvm_ref\` | \`$jvm_digest_ref\` |"
|
|
if [[ "$PUBLISH_NATIVE" == "true" ]]; then
|
|
echo "| \`$native_ref\` | \`$native_digest_ref\` |"
|
|
echo "| \`$compat_ref\` | \`$compat_digest_ref\` |"
|
|
fi
|
|
} >> "$GITHUB_STEP_SUMMARY"
|
|
|
|
- uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
|
|
with:
|
|
name: floci-image-provenance-${{ needs.prepare.outputs.image-tag }}
|
|
path: floci-image-provenance.json
|
|
if-no-files-found: error
|
|
retention-days: 30
|