Skip to content
Closed
Show file tree
Hide file tree
Changes from 19 commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
2054c21
Updating github-config
paketo-bot Mar 31, 2025
ff48ca5
Updating github-config
paketo-bot Apr 10, 2025
f628084
Updating github-config
paketo-bot May 2, 2025
51265dd
Updating github-config
paketo-bot May 17, 2025
a7d99cd
Updating github-config
paketo-bot May 18, 2025
345377c
Updating github-config
paketo-bot Jun 10, 2025
e3032fa
Updating github-config
paketo-bot Jun 15, 2025
c842899
Updating github-config
paketo-bot Jun 17, 2025
5d210d1
Updating github-config
paketo-bot Jun 20, 2025
d07afc4
Updating github-config
paketo-bot Jun 29, 2025
e5edf8e
Updating github-config
paketo-bot Jul 8, 2025
320fd8c
Updating github-config
paketo-bot Jul 15, 2025
bd4a52a
Updating github-config
paketo-bot Jul 18, 2025
a7e61cd
Updating github-config
paketo-bot Jul 19, 2025
5b29533
Updating github-config
paketo-bot Jul 22, 2025
9ae61d1
Updating github-config
paketo-bot Jul 30, 2025
7c6833f
Updating github-config
paketo-bot Aug 13, 2025
ca8eb0a
Updating github-config
paketo-bot Aug 14, 2025
4ac44f4
Updating github-config
paketo-bot Aug 16, 2025
30293ea
Updating github-config
paketo-bot Aug 22, 2025
c1c54ef
Updating github-config
paketo-bot Aug 23, 2025
3a58eb7
Updating github-config
paketo-bot Aug 24, 2025
094152e
Updating github-config
paketo-bot Sep 6, 2025
074d3b1
Updating github-config
paketo-bot Sep 12, 2025
5bf8076
Updating github-config
paketo-bot Sep 19, 2025
2fc9273
Updating github-config
paketo-bot Sep 23, 2025
e3e75d9
Updating github-config
paketo-bot Oct 8, 2025
92fcc46
Updating github-config
paketo-bot Oct 9, 2025
14d621b
Updating github-config
paketo-bot Oct 30, 2025
7025359
Updating github-config
paketo-bot Oct 31, 2025
6896f5a
Updating github-config
paketo-bot Nov 17, 2025
b4de9fc
Updating github-config
paketo-bot Nov 25, 2025
08c1ea7
Updating github-config
paketo-bot Nov 26, 2025
b4427bb
Updating github-config
paketo-bot Nov 28, 2025
f576b2a
Updating github-config
paketo-bot Dec 10, 2025
28ea557
Updating github-config
paketo-bot Dec 12, 2025
ed982b2
Updating github-config
paketo-bot Dec 13, 2025
6d5e429
Updating github-config
paketo-bot Dec 15, 2025
32a071f
Updating github-config
paketo-bot Dec 16, 2025
7c37063
Updating github-config
paketo-bot Dec 20, 2025
92c2612
Updating github-config
paketo-bot Dec 26, 2025
0010c64
Updating github-config
paketo-bot Jan 11, 2026
1a47ff5
Updating github-config
paketo-bot Jan 13, 2026
1eed6e2
Updating github-config
paketo-bot Jan 20, 2026
285790d
Updating github-config
paketo-bot Feb 4, 2026
abedb16
Updating github-config
paketo-bot Feb 7, 2026
b574fe0
Updating github-config
paketo-bot Feb 14, 2026
078e507
Updating github-config
paketo-bot Feb 15, 2026
bc9bf1b
Updating github-config
paketo-bot Feb 16, 2026
41fefb8
Updating github-config
paketo-bot Feb 21, 2026
d333c4f
Updating github-config
paketo-bot Mar 2, 2026
e94820f
Updating github-config
paketo-bot Mar 3, 2026
6e01474
Updating github-config
paketo-bot Mar 5, 2026
a26ec68
Updating github-config
paketo-bot Mar 6, 2026
19abc61
Updating github-config
paketo-bot Mar 7, 2026
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
6 changes: 3 additions & 3 deletions .github/workflows/approve-bot-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
download:
name: Download PR Artifact
if: ${{ github.event.workflow_run.event == 'pull_request' && github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
outputs:
pr-author: ${{ steps.pr-data.outputs.author }}
pr-number: ${{ steps.pr-data.outputs.number }}
Expand All @@ -32,7 +32,7 @@ jobs:
name: Approve Bot PRs
needs: download
if: ${{ needs.download.outputs.pr-author == 'paketo-bot' || needs.download.outputs.pr-author == 'dependabot[bot]' }}
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
steps:
- name: Check Commit Verification
id: unverified-commits
Expand All @@ -52,7 +52,7 @@ jobs:

- name: Checkout
if: steps.human-commits.outputs.human_commits == 'false' && steps.unverified-commits.outputs.unverified_commits == 'false'
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Approve
if: steps.human-commits.outputs.human_commits == 'false' && steps.unverified-commits.outputs.unverified_commits == 'false'
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ on:
pull_request:
branches: [ main ]
schedule:
- cron: '34 5 * * *' # daily at 5:34am UTC
- cron: '34 5 * * *' # daily at 5:34am UTC

jobs:
analyze:
name: Analyze
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04

strategy:
fail-fast: false
Expand All @@ -21,15 +21,15 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}

- name: Autobuild
uses: github/codeql-action/autobuild@v2
uses: github/codeql-action/autobuild@v3

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v3
106 changes: 106 additions & 0 deletions .github/workflows/compile-dependency.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
name: 'Compile Dependency on Target - Reusable Workflow'

description: |
Compiles Dependency on given target, os, and arch

on:
workflow_call:
inputs:
version:
description: 'dependency version'
required: true
type: string
target:
description: 'dependency OS target variant'
required: true
type: string
os:
description: 'platform OS (e.g., linux)'
required: true
type: string
arch:
description: 'platform architecture (e.g., amd64)'
required: true
type: string
shouldCompile:
description: 'whether to compile the dependency'
required: true
type: boolean
shouldTest:
description: 'whether to test the dependency after compilation'
required: true
type: boolean
uploadArtifactName:
description: 'name of the artifact to upload'
required: true
type: string

jobs:
compile:
# Speed up compilation by using runners that match os and arch when they are set, otherwise fall back to emulation.
runs-on: ${{ (inputs.os == 'linux' && inputs.arch == 'arm64') && 'ubuntu-24.04-arm' || 'ubuntu-24.04' }}

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Enable experimental features for Docker daemon and CLI
run: |
echo '{"experimental": true}' | sudo tee /etc/docker/daemon.json
sudo systemctl restart docker
mkdir -p ~/.docker
echo '{"experimental": "enabled"}' | sudo tee ~/.docker/config.json

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Setup before compilation
id: compile-setup
run: |
echo "outputdir=$(mktemp -d)" >> "$GITHUB_OUTPUT"

- name: docker build
id: docker-build
env:
SKIP_LOGIN: true
if: ${{ inputs.shouldCompile == true || inputs.shouldCompile == 'true' }}
uses: actions-hub/docker/cli@master
with:
args: "build ${{ (inputs.os != '' && inputs.arch != '') && format('--platform {0}/{1}', inputs.os, inputs.arch) || '' }} -t compilation -f dependency/actions/compile/${{ inputs.target }}.Dockerfile dependency/actions/compile"

- name: docker run
id: docker-run
uses: actions-hub/docker/cli@master
env:
SKIP_LOGIN: true
if: ${{ inputs.shouldCompile == true || inputs.shouldCompile == 'true' }}
with:
args: "run ${{ (inputs.os != '' && inputs.arch != '') && format('--platform {0}/{1}', inputs.os, inputs.arch) || '' }} -v ${{ steps.compile-setup.outputs.outputdir }}:/home compilation --outputDir /home --target ${{ inputs.target }} --version ${{ inputs.version }} ${{ inputs.os != '' && format('--os {0}', inputs.os) || '' }} ${{ inputs.arch != '' && format('--arch {0}', inputs.arch) || '' }}"

- name: Print contents of output dir
shell: bash
run: ls -lah ${{ steps.compile-setup.outputs.outputdir }}

- name: Test Dependency
working-directory: dependency
if: ${{ (inputs.shouldCompile == true || inputs.shouldCompile == 'true') && (inputs.shouldTest == true || inputs.shouldTest == 'true') }}
run: |
#!/usr/bin/env bash
set -euo pipefail
shopt -s inherit_errexit

make test \
version="${{ inputs.version }}" \
tarballPath="${{ steps.compile-setup.outputs.outputdir }}/*.tgz" \
os="${{ inputs.os }}" \
arch="${{ inputs.arch }}"

- name: Upload compiled artifact
uses: actions/upload-artifact@v4
if: ${{ inputs.shouldCompile == true || inputs.shouldCompile == 'true' }}
with:
name: '${{ inputs.uploadArtifactName }}'
path: '${{ steps.compile-setup.outputs.outputdir }}/*'
131 changes: 99 additions & 32 deletions .github/workflows/create-draft-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,16 @@ concurrency: release
jobs:
unit:
name: Unit Tests
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
outputs:
builders: ${{ steps.builders.outputs.builders }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v3
uses: actions/setup-go@v5
with:
go-version: 'stable'
- name: Checkout
uses: actions/checkout@v3
go-version-file: go.mod
- name: Run Unit Tests
run: ./scripts/unit.sh
- name: Get builders from integration.json
Expand All @@ -39,39 +39,45 @@ jobs:

integration:
name: Integration Tests
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
needs: unit
strategy:
matrix:
builder: ${{ fromJSON(needs.unit.outputs.builders) }}
fail-fast: false # don't cancel all test jobs when one fails
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v3
uses: actions/setup-go@v5
with:
go-version: 'stable'
- name: Checkout
uses: actions/checkout@v3
go-version-file: go.mod
- name: Run Integration Tests
run: ./scripts/integration.sh --builder ${{ matrix.builder }} --token ${{ github.token }}
env:
TMPDIR: "${{ runner.temp }}"

release:
name: Release
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
needs: integration
steps:
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: 'stable'
services:
registry:
image: registry:2
ports:
- 5000:5000

steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-tags: true

- name: Setup Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod

- name: Reset Draft Release
id: reset
uses: paketo-buildpacks/github-config/actions/release/reset-draft@main
Expand Down Expand Up @@ -110,13 +116,86 @@ jobs:
echo "buildpack_type=buildpack" >> "$GITHUB_OUTPUT"
fi

- name: Get buildpack path
id: get_buildpack_path
run: |

if [ -f "build/buildpackage.cnb" ]; then
echo "path=build/buildpackage.cnb" >> "$GITHUB_OUTPUT"
else
echo "path=build/buildpackage-linux-amd64.cnb" >> "$GITHUB_OUTPUT"
fi

- name: Create Release Notes
id: create-release-notes
uses: paketo-buildpacks/github-config/actions/release/notes@main
with:
repo: ${{ github.repository }}
token: ${{ secrets.PAKETO_BOT_GITHUB_TOKEN }}
buildpack_type: ${{ steps.get_buildpack_type.outputs.buildpack_type }}
buildpackage_path: ${{ steps.get_buildpack_path.outputs.path }}

- name: Get Image Digest
id: image_digest
run: |
image_name="localhost:5000/npm-install:latest"

./scripts/publish.sh \
--buildpack-type ${{ steps.get_buildpack_type.outputs.buildpack_type }} \
--image-ref $image_name

echo "digest=$(sudo skopeo inspect "docker://${image_name}" --tls-verify=false | jq -r .Digest)" >> "$GITHUB_OUTPUT"

- name: Set Correct Image Digest on the Release notes
run: |
printf '${{ steps.create-release-notes.outputs.release_body }}' \
| sed -E \
"s/\*\*Digest:\*\* \`sha256:[a-f0-9]{64}\`/\*\*Digest:\*\* \`${{ steps.image_digest.outputs.digest }}\`/" \
> ./release_notes

printf '${{ steps.image_digest.outputs.digest }}' > ./index-digest.sha256

- name: Create release assets
id: create_release_assets
run: |
release_assets=$(jq -n --arg repo_name "${{ github.event.repository.name }}" --arg tag "${{ steps.tag.outputs.tag }}" '
[
{
"path": "build/buildpack.tgz",
"name": ($repo_name + "-" + $tag + ".tgz"),
"content_type": "application/gzip"
},
{
"path": "./index-digest.sha256",
"name": ($repo_name + "-" + $tag + "-" + "index-digest.sha256"),
"content_type": "text/plain"
}
]')

for filepath in build/*.cnb; do
filename=$(basename "$filepath")
asset_name=""
if [[ "$filename" == "buildpackage-linux-amd64.cnb" ]]; then
asset_name="${{ github.event.repository.name }}-${{ steps.tag.outputs.tag }}.cnb"
elif [[ "$filename" == "buildpackage.cnb" ]]; then
asset_name="${{ github.event.repository.name }}-${{ steps.tag.outputs.tag }}.cnb"
else
formatted_filename="${filename#buildpackage-}"
asset_name="${{ github.event.repository.name }}-${{ steps.tag.outputs.tag }}-${formatted_filename}"
fi

release_assets=$(echo "$release_assets" | jq --arg asset_name "${asset_name}" --arg filepath "$filepath" '
. + [
{
"path": $filepath,
"name": $asset_name,
"content_type": "application/gzip"
}
]')
done

release_assets=$(jq -c <<< "$release_assets" )
printf "release_assets=%s\n" "${release_assets}" >> "$GITHUB_OUTPUT"

- name: Create Release
uses: paketo-buildpacks/github-config/actions/release/create@main
Expand All @@ -126,25 +205,13 @@ jobs:
tag_name: v${{ steps.tag.outputs.tag }}
target_commitish: ${{ github.sha }}
name: v${{ steps.tag.outputs.tag }}
body: ${{ steps.create-release-notes.outputs.release_body }}
body_filepath: "./release_notes"
draft: true
assets: |
[
{
"path": "build/buildpack.tgz",
"name": "${{ github.event.repository.name }}-${{ steps.tag.outputs.tag }}.tgz",
"content_type": "application/gzip"
},
{
"path": "build/buildpackage.cnb",
"name": "${{ github.event.repository.name }}-${{ steps.tag.outputs.tag }}.cnb",
"content_type": "application/gzip"
}
]
assets: ${{ steps.create_release_assets.outputs.release_assets }}

failure:
name: Alert on Failure
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
needs: [ unit, integration, release ]
if: ${{ always() && needs.unit.result == 'failure' || needs.integration.result == 'failure' || needs.release.result == 'failure' }}
steps:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/label-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ concurrency: pr_labels_${{ github.event.number }}
jobs:
autolabel:
name: Ensure Minimal Semver Labels
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
steps:
- name: Check Minimal Semver Labels
uses: mheap/github-action-required-labels@v3
uses: mheap/github-action-required-labels@v5
with:
count: 1
labels: semver:major, semver:minor, semver:patch
Expand Down
Loading
Loading