Remove opentelemetry-operator automation (#8728)

This commit is contained in:
Trask Stalnaker 2023-06-15 08:56:20 -07:00 committed by GitHub
parent 7719a91734
commit 827236e749
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 87 deletions

View File

@ -219,11 +219,3 @@ jobs:
gh pr create --title "$message" \
--body "$body" \
--base main
create-operator-pull-request:
needs: release
uses: ./.github/workflows/reusable-create-operator-pull-request.yml
with:
version: ${{ needs.release.outputs.version }}
secrets:
OPENTELEMETRYBOT_GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}

View File

@ -1,79 +0,0 @@
name: Reusable - Create operator pull request
on:
workflow_call:
inputs:
version:
type: string
required: true
secrets:
OPENTELEMETRYBOT_GITHUB_TOKEN:
required: true
# to help with partial release build failures
workflow_dispatch:
inputs:
version:
description: "Version"
required: true
jobs:
create-operator-pull-request:
runs-on: ubuntu-latest
steps:
- name: Sync opentelemetry-operator fork
env:
# this is the personal access token used for "gh repo sync" below
GH_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
run: |
# synchronizing the fork is fast, and avoids the need to fetch the full upstream repo
# (fetching the upstream repo with "--depth 1" would lead to "shallow update not allowed"
# error when pushing back to the origin repo)
gh repo sync opentelemetrybot/opentelemetry-operator \
--source open-telemetry/opentelemetry-operator \
--force
- uses: actions/checkout@v3
with:
repository: opentelemetrybot/opentelemetry-operator
# this is the personal access token used for "git push" below
token: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
- name: Update version
env:
VERSION: ${{ inputs.version }}
run: |
echo $VERSION > autoinstrumentation/java/version.txt
- name: Use CLA approved github bot
run: |
# cannot run the use-cla-approved-github-bot.sh script here since in a different repo
git config user.name opentelemetrybot
git config user.email 107717825+opentelemetrybot@users.noreply.github.com
- name: Create pull request against opentelemetry-operator
env:
VERSION: ${{ inputs.version }}
# this is the personal access token used for "gh pr create" below
GH_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
run: |
message="Update the javaagent version to $VERSION"
# note that @open-telemetry/java-instrumentation-approvers cannot be used below
# because opentelemetrybot is not a member of the OpenTelemetry org,
# and so it cannot @ mention OpenTelemetry org groups
body="Update the javaagent version to \`$VERSION\`.
cc @laurit @mateuszrzeszutek @trask
"
branch="update-opentelemetry-javaagent-to-${VERSION}"
# gh pr create doesn't have a way to explicitly specify different head and base
# repositories currently, but it will implicitly pick up the head from a different
# repository if you set up a tracking branch
git checkout -b $branch
git commit -a -m "$message"
git push --set-upstream origin $branch
gh pr create --title "$message" \
--body "$body" \
--repo open-telemetry/opentelemetry-operator \
--base main