Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename Release workflows #1179

Merged
merged 8 commits into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: PR-release Integration Gardener
name: "Release PR Integration Gardener"

on:
workflow_call:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This workflow is responsible for all kinds of integration tests run on pull request.
# Those tests depend on a container image so in the first job we wait for the image build to succeed.

name: Release Pull Request integration tests
name: "Release PR Integration"

on:
workflow_call:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
config/ui-extensions/**
config/crd/**
tests/ui/**
.github/workflows/ui-tests.yaml
.github/workflows/call-ui-tests.yaml
- uses: ./.github/actions/load-manager-image
- uses: actions/setup-go@v5
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pull-add-bot-prs-to-project.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
}
}
}' -f org=$ORGANIZATION -F number=$PROJECT_NUMBER > project_data.json

echo 'PROJECT_ID='$(jq '.data.organization.projectV2.id' project_data.json) >> $GITHUB_ENV

echo 'READY_ID='$(jq '.data.organization.projectV2.fields.nodes[] | select(.name== "Ready") | .id' project_data.json) >> $GITHUB_ENV
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pull-request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,13 @@ jobs:
ui-tests:
name: Dispatch UI tests
needs: [build-image]
uses: ./.github/workflows/ui-tests.yaml
uses: ./.github/workflows/call-ui-tests.yaml
if: github.event.pull_request.draft == false
secrets: inherit

verify-pins:
name: Dispatch verify-commit-pins
uses: ./.github/workflows/verify-commit-pins.yaml
uses: ./.github/workflows/call-verify-commit-pins.yaml
if: github.event.pull_request.draft == false
secrets: inherit

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: "Create release"
name: "Create Release"

on:
workflow_dispatch:
inputs:
name:
description: "Create release"
version:
description: "Version"
videlov marked this conversation as resolved.
Show resolved Hide resolved
default: ""
required: true
since:
Expand Down Expand Up @@ -32,10 +32,10 @@ jobs:
- name: Check security-scanner config
shell: bash
run: |
if [[ $( yq eval ".protecode[0]" sec-scanners-config.yaml ) == "europe-docker.pkg.dev/kyma-project/prod/istio/releases/istio-manager:${{ github.event.inputs.name }}" ]]; then
if [[ $( yq eval ".protecode[0]" sec-scanners-config.yaml ) == "europe-docker.pkg.dev/kyma-project/prod/istio/releases/istio-manager:${{ github.event.inputs.version }}" ]]; then
exit 0
else
echo "Error: istio-manager image tag in sec-scanners-config doesn't match release ${{ github.event.inputs.name }}"
echo "Error: istio-manager image tag in sec-scanners-config doesn't match release ${{ github.event.inputs.version }}"
exit 1
fi

Expand All @@ -47,8 +47,8 @@ jobs:
dockerfile: Dockerfile
context: .
build-args: |
VERSION=${{ github.event.inputs.name }}
tags: "${{ github.event.inputs.name }}"
VERSION=${{ github.event.inputs.version }}
tags: "${{ github.event.inputs.version }}"

build-image-experimental:
uses: kyma-project/test-infra/.github/workflows/image-builder.yml@main
Expand All @@ -58,9 +58,9 @@ jobs:
dockerfile: Dockerfile
context: .
build-args: |
VERSION=${{ github.event.inputs.name }}-experimental
VERSION=${{ github.event.inputs.version }}-experimental
GO_BUILD_TAGS=experimental
tags: "${{ github.event.inputs.name }}-experimental"
tags: "${{ github.event.inputs.version }}-experimental"

unit-tests:
uses: ./.github/workflows/call-unit-lint.yaml
Expand All @@ -69,7 +69,7 @@ jobs:
needs: [build-image, build-image-experimental, unit-tests]
uses: ./.github/workflows/call-integration-tests.yaml
with:
image: "europe-docker.pkg.dev/kyma-project/prod/istio/releases/istio-manager:${{ github.event.inputs.name }}"
image: "europe-docker.pkg.dev/kyma-project/prod/istio/releases/istio-manager:${{ github.event.inputs.version }}"
secrets: inherit

create-draft:
Expand All @@ -85,22 +85,22 @@ jobs:
- name: Create changelog
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: ./scripts/create_changelog.sh ${{ github.event.inputs.name }} ${{ github.event.inputs.since }}
run: ./scripts/create_changelog.sh ${{ github.event.inputs.version }} ${{ github.event.inputs.since }}

- name: Create draft release
id: create-draft
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
RELEASE_ID=$(./scripts/create_draft_release.sh ${{ github.event.inputs.name }})
RELEASE_ID=$(./scripts/create_draft_release.sh ${{ github.event.inputs.version }})
echo "release_id=$RELEASE_ID" >> $GITHUB_OUTPUT

- name: Create lightweight tag
run: |
git tag ${{ github.event.inputs.name }}
git push origin ${{ github.event.inputs.name }}
git tag ${{ github.event.inputs.name }}-experimental
git push origin ${{ github.event.inputs.name }}-experimental
git tag ${{ github.event.inputs.version }}
git push origin ${{ github.event.inputs.version }}
git tag ${{ github.event.inputs.version }}-experimental
git push origin ${{ github.event.inputs.version }}-experimental

outputs:
release_id: ${{ steps.create-draft.outputs.release_id }}
Expand All @@ -118,7 +118,7 @@ jobs:
- name: Publish release assets
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: ./scripts/publish_assets.sh ${{ github.event.inputs.name }} ${{ needs.create-draft.outputs.release_id }}
run: ./scripts/publish_assets.sh ${{ github.event.inputs.version }} ${{ needs.create-draft.outputs.release_id }}

- name: Publish release
env:
Expand All @@ -138,4 +138,4 @@ jobs:
payload-templated: true
payload: |
repository: ${{ github.repository }},
release: ${{ inputs.name }}
release: ${{ inputs.version }}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Release Pull Request pipeline
name: "Release PR"
on:
pull_request_target:
types: [ synchronize, opened, reopened, ready_for_review ]
Expand Down Expand Up @@ -43,27 +43,27 @@ jobs:
integration-tests:
name: Dispatch integration tests
needs: [upload-image]
uses: ./.github/workflows/pull-integration-release.yaml
uses: ./.github/workflows/call-release-pr-integration.yaml
if: github.event.pull_request.draft == false
secrets: inherit

integration-tests-gardener:
name: Dispatch Gardener integration tests
needs: [upload-image]
uses: ./.github/workflows/pull-integration-gardener-release.yaml
uses: ./.github/workflows/call-release-pr-integration-gardener.yaml
if: github.event.pull_request.draft == false
secrets: inherit

ui-tests:
name: Dispatch UI tests
needs: [upload-image]
uses: ./.github/workflows/ui-tests.yaml
uses: ./.github/workflows/call-ui-tests.yaml
if: github.event.pull_request.draft == false
secrets: inherit

verify-pins:
name: Dispatch verify-commit-pins
uses: ./.github/workflows/verify-commit-pins.yaml
uses: ./.github/workflows/call-verify-commit-pins.yaml
if: github.event.pull_request.draft == false
secrets: inherit

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

name: Rollout to channel via module-manifests
name: Release rollout to channel via module-manifests
# Workflow requires the following variables to be defined
# GIT_USER_NAME - user creating head branch and PR
# GIT_USER_EMAIL - this user email
Expand Down Expand Up @@ -73,13 +73,13 @@ jobs:
shell: bash
run: |
tags=$(curl -s -H "Accept: application/vnd.github+json" ${ISTIO_API_URL}/tags | jq -r '.[] | .name')

if echo $tags | tr " " '\n' | grep -F -q -x ${{ inputs.releaseTag }}; then
echo "TAG=${{ inputs.releaseTag }}" >> $GITHUB_ENV
echo "tag found"
else
echo "tag not found: ${{ inputs.releaseTag }}"
exit 1
exit 1
fi
- name: Set branch name
shell: bash
Expand Down Expand Up @@ -130,7 +130,7 @@ jobs:
MODULE_VERSION="${TAG}"
FILE_NAME="${MANIFEST_FILENAME}"
fi

cat <<EOF | tee module-config.yaml
name: ${FULL_MODULE_NAME}
channel: ${CHANNEL}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update-sec-scanner.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"

git fetch origin
git checkout -f autobump/sec-scanners-config
git reset --hard origin/main
Expand Down
Loading
Loading