-
Notifications
You must be signed in to change notification settings - Fork 165
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Tom Kennedy <[email protected]>
- Loading branch information
1 parent
a3edeb3
commit 9d4cfce
Showing
3 changed files
with
63 additions
and
77 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,9 +5,8 @@ on: | |
branches: | ||
- main | ||
- release/** | ||
pull_request: | ||
branches: | ||
- release/** | ||
tags: | ||
- v[0-9]+.[0-9]+.[0-9]+-?** | ||
|
||
defaults: | ||
run: | ||
|
@@ -23,7 +22,7 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
|
@@ -42,9 +41,9 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
|
@@ -60,9 +59,9 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
|
@@ -78,9 +77,9 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
|
@@ -96,9 +95,9 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
|
@@ -114,9 +113,9 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
|
@@ -132,9 +131,9 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
|
@@ -150,9 +149,9 @@ jobs: | |
runs-on: windows-2019 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
|
@@ -170,9 +169,9 @@ jobs: | |
runs-on: windows-2019 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
|
@@ -190,13 +189,21 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Docker Login | ||
uses: docker/[email protected] | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
password: ${{ secrets.REGISTRY_PASSWORD }} | ||
- name: Set up Go | ||
uses: actions/setup-go@v4 | ||
with: | ||
go-version-file: 'go.mod' | ||
- name: Build | ||
run: | | ||
trap 'echo -e "$output"' EXIT | ||
output=$(go run ./hack/lifecycle/main.go --tag=${{ env.PUBLIC_IMAGE_DEV_REPO }}/lifecycle 2>&1) | ||
image=$(echo "$output" | grep "saved lifecycle" | awk -F "saved lifecycle image: " '{print $2}') | ||
mkdir images | ||
|
@@ -221,7 +228,7 @@ jobs: | |
- completion-windows-image | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v4 | ||
|
@@ -240,17 +247,17 @@ jobs: | |
name: images | ||
|
||
- name: Build release yaml | ||
run: | | ||
run: | | ||
ytt -f config/ \ | ||
-v controller_image=$(cat controller) \ | ||
-v webhook_image=$(cat webhook) \ | ||
-v build_init_image=$(cat build-init) \ | ||
-v build_init_windows_image=$(cat build-init-windows) \ | ||
-v build_waiter_image=$(cat build-waiter) \ | ||
-v rebase_image=$(cat rebase) \ | ||
-v completion_image=$(cat completion) \ | ||
-v completion_windows_image=$(cat completion-windows) \ | ||
-v lifecycle_image=$(cat lifecycle) > prerelease.yaml | ||
-v controller.image=$(cat controller) \ | ||
-v webhook.image=$(cat webhook) \ | ||
-v build_init.image=$(cat build-init) \ | ||
-v build_init_windows.image=$(cat build-init-windows) \ | ||
-v build_waiter.image=$(cat build-waiter) \ | ||
-v rebase.image=$(cat rebase) \ | ||
-v completion.image=$(cat completion) \ | ||
-v completion_windows.image=$(cat completion-windows) \ | ||
-v lifecycle.image=$(cat lifecycle) > prerelease.yaml | ||
cat prerelease.yaml | ||
|
@@ -275,7 +282,7 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v4 | ||
|
@@ -343,13 +350,13 @@ jobs: | |
EOF | ||
- name: Create Kind Cluster | ||
uses: helm/kind-action@v1.7.0 | ||
uses: helm/kind-action@v1.8.0 | ||
with: | ||
cluster_name: e2e | ||
config: kind.yaml | ||
|
||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ env.REGISTRY_URL }} | ||
username: ${{ env.REGISTRY_USER }} | ||
|
@@ -428,11 +435,11 @@ jobs: | |
- build-init-windows-image | ||
- completion-windows-image | ||
- lifecycle-image | ||
if: ${{ startsWith(github.ref, 'refs/heads/release/') }} | ||
if: ${{ startsWith(github.ref, 'refs/tags/v') }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v4 | ||
|
@@ -452,16 +459,16 @@ jobs: | |
uses: actions/download-artifact@v3 | ||
|
||
- name: Docker Login | ||
uses: docker/login-action@v2.2.0 | ||
uses: docker/login-action@v3.0.0 | ||
with: | ||
registry: ${{ secrets.REGISTRY_HOST }} | ||
username: ${{ secrets.REGISTRY_USER }} | ||
password: ${{ secrets.REGISTRY_PASSWORD }} | ||
|
||
- name: Parse branch name | ||
- name: Parse tag name | ||
run: | | ||
echo "GITHUB_REF=${GITHUB_REF}" | ||
[[ $GITHUB_REF =~ ^refs\/heads\/release\/(.*)$ ]] && version=${BASH_REMATCH[1]} | ||
[[ $GITHUB_REF =~ ^refs\/tags\/v(.*)$ ]] && version=${BASH_REMATCH[1]} | ||
if [[ -z "${version}" ]]; then | ||
echo "ERROR: kpack version not detected." | ||
exit 1 | ||
|
@@ -474,12 +481,12 @@ jobs: | |
for image in images/*; do | ||
dev_image=$(cat $image) | ||
digest=$(echo $dev_image| cut -d "@" -f 2) | ||
name=$(basename $image) | ||
final_repo="${{ env.PUBLIC_IMAGE_REPO }}/${name}" | ||
final_repo="${{ env.PUBLIC_IMAGE_REPO }}/${name}" | ||
crane copy "$dev_image" "$final_repo" | ||
echo "${final_repo}@${digest}" > final-image-refs/$name | ||
done | ||
|
@@ -494,16 +501,16 @@ jobs: | |
run: | | ||
file="release-${{ env.KPACK_VERSION }}.yaml" | ||
ytt -f config/ \ | ||
-v controller_image=$(cat final-image-refs/controller) \ | ||
-v webhook_image=$(cat final-image-refs/webhook) \ | ||
-v build_init_image=$(cat final-image-refs/build-init) \ | ||
-v build_init_windows_image=$(cat final-image-refs/build-init-windows) \ | ||
-v build_waiter_image=$(cat final-image-refs/build-waiter) \ | ||
-v rebase_image=$(cat final-image-refs/rebase) \ | ||
-v completion_image=$(cat final-image-refs/completion) \ | ||
-v completion_windows_image=$(cat final-image-refs/completion-windows) \ | ||
-v lifecycle_image=$(cat final-image-refs/lifecycle) \ | ||
-v version=${{ env.KPACK_VERSION }} > $file | ||
-v controller.image=$(cat final-image-refs/controller) \ | ||
-v webhook.image=$(cat final-image-refs/webhook) \ | ||
-v build_init.image=$(cat final-image-refs/build-init) \ | ||
-v build_init_windows.image=$(cat final-image-refs/build-init-windows) \ | ||
-v build_waiter.image=$(cat final-image-refs/build-waiter) \ | ||
-v rebase.image=$(cat final-image-refs/rebase) \ | ||
-v completion.image=$(cat final-image-refs/completion) \ | ||
-v completion_windows.image=$(cat final-image-refs/completion-windows) \ | ||
-v lifecycle.image=$(cat final-image-refs/lifecycle) \ | ||
-v kpack_version=${{ env.KPACK_VERSION }} > $file | ||
echo "sha=$(shasum -a 256 $file)" >> $GITHUB_OUTPUT | ||
- name: Upload Release | ||
|
@@ -534,4 +541,4 @@ jobs: | |
${{ steps.release_yaml.outputs.sha }} | ||
``` | ||
**Full Changelog**: | ||
**Full Changelog**: |
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
* @matthewmcnew @tomkennedy513 @chenbh @pviraj59 | ||
* @buildpacks-community/kpack-maintainers |