Skip to content
This repository was archived by the owner on Jan 10, 2025. It is now read-only.
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
2 changes: 1 addition & 1 deletion .github/workflows/bundle-push.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
workflow_dispatch:

jobs:
container:
bundle:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down
47 changes: 47 additions & 0 deletions .github/workflows/check-upstream.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Check Upstream Chart Version
on:
schedule: 0 8 * * 1
workflow_dispatch:

jobs:
check-local-version:
name: Check Local Version
runs-on: ubuntu-latest
outputs:
update: ${{ steps.compare.outputs.update }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Helm Install
uses: azure/setup-helm@v3

- name: Compare Versions
id: compare
run: |
CHART_PATH="simple-arc-operator/helm-charts/actions-runner-controller/Chart.yaml"
LOCAL_VERSION=$(grep -Po "(?<=version: )(\d+.?){3}" $CHART_PATH)

helm repo add actions-runner-controller \
https://actions-runner-controller.github.io/actions-runner-controller

helm repo update

UPSTREAM_VERSION=$(helm search repo actions-runner-controller -o json | jq -r .[0].version)

if [ "$LOCAL_VERSION" == "$UPSTREAM_VERSION" ]; then
echo "Versions match"
echo "update=false" >> $GITHUB_OUTPUT
else
echo "Versions do not match"
echo "update=true" >> $GITHUB_OUTPUT
fi

echo "Local: $LOCAL_VERSION"
echo "Upstream: $UPSTREAM_VERSION"

generate-operator:
needs: check-local-version
if: needs.check-local-version.outputs.update == 'true'
uses: ./.github/workflows/generate-operator.yaml
9 changes: 3 additions & 6 deletions .github/workflows/generate-operator.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
name: GitHub Actions Demo
name: Generate Operator
on:
push:
branches:
- codify-changes
workflow_dispatch:
workflow_call:

jobs:
containers:
generate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/runner-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ on:
workflow_dispatch:

jobs:
container:
test:
runs-on: ['self-hosted', 'Linux', 'X64']
steps:
- run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event."
Expand Down