Skip to content

Commit 526bf79

Browse files
authored
Merge branch 'main' into token-permissions
2 parents 38e0fb8 + c30b8fa commit 526bf79

File tree

33 files changed

+676
-140
lines changed

33 files changed

+676
-140
lines changed
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/bin/bash -e
22

3-
git config user.name opentelemetrybot
4-
git config user.email 107717825+opentelemetrybot@users.noreply.github.com
3+
git config user.name otelbot
4+
git config user.email 197425009+otelbot@users.noreply.github.com

.github/workflows/backport.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,22 @@ jobs:
3030
- name: Use CLA approved github bot
3131
run: .github/scripts/use-cla-approved-github-bot.sh
3232

33+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
34+
id: otelbot-token
35+
with:
36+
app-id: ${{ vars.OTELBOT_APP_ID }}
37+
private-key: ${{ secrets.OTELBOT_PRIVATE_KEY }}
38+
3339
- name: Create pull request
3440
env:
3541
NUMBER: ${{ github.event.inputs.number }}
3642
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
37-
GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
43+
GITHUB_TOKEN: ${{ steps.otelbot-token.outputs.token }}
3844
run: |
3945
commit=$(gh pr view $NUMBER --json mergeCommit --jq .mergeCommit.oid)
4046
title=$(gh pr view $NUMBER --json title --jq .title)
4147
42-
branch="opentelemetrybot/backport-${NUMBER}-to-${GITHUB_REF_NAME//\//-}"
48+
branch="otelbot/backport-${NUMBER}-to-${GITHUB_REF_NAME//\//-}"
4349
4450
git cherry-pick $commit
4551
git push origin HEAD:$branch

.github/workflows/changelog.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
runs-on: ubuntu-latest
1919
if: |
2020
!contains(github.event.pull_request.labels.*.name, 'Skip Changelog')
21-
&& github.actor != 'opentelemetrybot'
21+
&& github.actor != 'otelbot[bot]'
2222
2323
steps:
2424
- uses: actions/checkout@v4

.github/workflows/generate_workflows_lib/src/generate_workflows_lib/misc.yml.j2

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,16 +36,16 @@ jobs:
3636
{%- if job_data == "generate-workflows" %}
3737
if: |
3838
!contains(github.event.pull_request.labels.*.name, 'Skip generate-workflows')
39-
&& github.event.pull_request.user.login != 'opentelemetrybot' && github.event_name == 'pull_request'
39+
&& github.event.pull_request.user.login != 'otelbot[bot]' && github.event_name == 'pull_request'
4040
{%- endif %}
4141
{%- if job_data == "public-symbols-check" %}
4242
if: |
4343
!contains(github.event.pull_request.labels.*.name, 'Approve Public API check')
44-
&& github.actor != 'opentelemetrybot' && github.event_name == 'pull_request'
44+
&& github.actor != 'otelbot[bot]' && github.event_name == 'pull_request'
4545
{%- endif %}
4646
{%- if job_data == "docs" %}
4747
if: |
48-
github.event.pull_request.user.login != 'opentelemetrybot' && github.event_name == 'pull_request'
48+
github.event.pull_request.user.login != 'otelbot[bot]' && github.event_name == 'pull_request'
4949
{%- endif %}
5050
steps:
5151
- name: Checkout repo @ SHA - ${% raw %}{{ github.sha }}{% endraw %}

.github/workflows/misc_0.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
runs-on: ubuntu-latest
7575
timeout-minutes: 30
7676
if: |
77-
github.event.pull_request.user.login != 'opentelemetrybot' && github.event_name == 'pull_request'
77+
github.event.pull_request.user.login != 'otelbot[bot]' && github.event_name == 'pull_request'
7878
steps:
7979
- name: Checkout repo @ SHA - ${{ github.sha }}
8080
uses: actions/checkout@v4
@@ -118,7 +118,7 @@ jobs:
118118
timeout-minutes: 30
119119
if: |
120120
!contains(github.event.pull_request.labels.*.name, 'Skip generate-workflows')
121-
&& github.event.pull_request.user.login != 'opentelemetrybot' && github.event_name == 'pull_request'
121+
&& github.event.pull_request.user.login != 'otelbot[bot]' && github.event_name == 'pull_request'
122122
steps:
123123
- name: Checkout repo @ SHA - ${{ github.sha }}
124124
uses: actions/checkout@v4

.github/workflows/package-prepare-patch-release.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,13 +110,19 @@ jobs:
110110
- name: Use CLA approved github bot
111111
run: .github/scripts/use-cla-approved-github-bot.sh
112112

113+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
114+
id: otelbot-token
115+
with:
116+
app-id: ${{ vars.OTELBOT_APP_ID }}
117+
private-key: ${{ secrets.OTELBOT_PRIVATE_KEY }}
118+
113119
- name: Create pull request
114120
env:
115121
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
116-
GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
122+
GITHUB_TOKEN: ${{ steps.otelbot-token.outputs.token }}
117123
run: |
118124
message="Prepare patch release for ${PACKAGE_NAME} v${NEXT_VERSION}"
119-
branch="opentelemetrybot/patch-${PACKAGE_NAME}-version-to-v${NEXT_VERSION}"
125+
branch="otelbot/patch-${PACKAGE_NAME}-version-to-v${NEXT_VERSION}"
120126
121127
git commit -a -m "$message"
122128
git push origin HEAD:$branch

.github/workflows/package-prepare-release.yml

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -135,13 +135,19 @@ jobs:
135135
- name: Use CLA approved github bot
136136
run: .github/scripts/use-cla-approved-github-bot.sh
137137

138+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
139+
id: otelbot-token
140+
with:
141+
app-id: ${{ vars.OTELBOT_APP_ID }}
142+
private-key: ${{ secrets.OTELBOT_PRIVATE_KEY }}
143+
138144
- name: Create pull request against the release branch
139145
env:
140146
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
141-
GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
147+
GITHUB_TOKEN: ${{ steps.otelbot-token.outputs.token }}
142148
run: |
143149
message="Prepare release for ${PACKAGE_NAME} v${VERSION}"
144-
branch="opentelemetrybot/prepare-${RELEASE_BRANCH_NAME}"
150+
branch="otelbot/prepare-${RELEASE_BRANCH_NAME}"
145151
146152
git commit -a -m "$message"
147153
git push origin HEAD:$branch
@@ -190,14 +196,20 @@ jobs:
190196
- name: Use CLA approved github bot
191197
run: .github/scripts/use-cla-approved-github-bot.sh
192198

199+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
200+
id: otelbot-token-main
201+
with:
202+
app-id: ${{ vars.OTELBOT_APP_ID }}
203+
private-key: ${{ secrets.OTELBOT_PRIVATE_KEY }}
204+
193205
- name: Create pull request against main
194206
env:
195207
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
196-
GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
208+
GITHUB_TOKEN: ${{ steps.otelbot-token-main.outputs.token }}
197209
run: |
198210
message="Update ${PACKAGE_NAME} version to v${NEXT_VERSION}"
199211
body="Update \`${PACKAGE_NAME}\` version to v\`${NEXT_VERSION}\`."
200-
branch="opentelemetrybot/update-${PACKAGE_NAME}-version-to-v${NEXT_VERSION}"
212+
branch="otelbot/update-${PACKAGE_NAME}-version-to-v${NEXT_VERSION}"
201213
202214
git commit -a -m "$message"
203215
git push origin HEAD:$branch

.github/workflows/package-release.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,14 +141,20 @@ jobs:
141141
- name: Use CLA approved github bot
142142
run: .github/scripts/use-cla-approved-github-bot.sh
143143

144+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
145+
id: otelbot-token
146+
with:
147+
app-id: ${{ vars.OTELBOT_APP_ID }}
148+
private-key: ${{ secrets.OTELBOT_PRIVATE_KEY }}
149+
144150
- name: Create pull request against main
145151
env:
146152
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
147-
GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
153+
GITHUB_TOKEN: ${{ steps.otelbot-token.outputs.token }}
148154
run: |
149155
message="Copy changelog updates from $GITHUB_REF_NAME"
150156
body="Copy changelog updates from \`$GITHUB_REF_NAME\`."
151-
branch="opentelemetrybot/changelog-${GITHUB_REF_NAME//\//-}"
157+
branch="otelbot/changelog-${GITHUB_REF_NAME//\//-}"
152158
153159
if [[ -z $PRIOR_VERSION_WHEN_PATCH ]]; then
154160
if git diff --quiet; then

.github/workflows/prepare-patch-release.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,14 +76,20 @@ jobs:
7676
- name: Use CLA approved github bot
7777
run: .github/scripts/use-cla-approved-github-bot.sh
7878

79+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
80+
id: otelbot-token
81+
with:
82+
app-id: ${{ vars.OTELBOT_APP_ID }}
83+
private-key: ${{ secrets.OTELBOT_PRIVATE_KEY }}
84+
7985
- name: Create pull request
8086
id: create_pr
8187
env:
8288
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
83-
GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
89+
GITHUB_TOKEN: ${{ steps.otelbot-token.outputs.token }}
8490
run: |
8591
message="Prepare release ${STABLE_VERSION}/${UNSTABLE_VERSION}"
86-
branch="opentelemetrybot/prepare-release-${STABLE_VERSION}-${UNSTABLE_VERSION}"
92+
branch="otelbot/prepare-release-${STABLE_VERSION}-${UNSTABLE_VERSION}"
8793
8894
git commit -a -m "$message"
8995
git push origin HEAD:$branch

.github/workflows/prepare-release-branch.yml

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,14 +99,20 @@ jobs:
9999
- name: Use CLA approved github bot
100100
run: .github/scripts/use-cla-approved-github-bot.sh
101101

102+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
103+
id: otelbot-token
104+
with:
105+
app-id: ${{ vars.OTELBOT_APP_ID }}
106+
private-key: ${{ secrets.OTELBOT_PRIVATE_KEY }}
107+
102108
- name: Create pull request against the release branch
103109
id: create_release_branch_pr
104110
env:
105111
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
106-
GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
112+
GITHUB_TOKEN: ${{ steps.otelbot-token.outputs.token }}
107113
run: |
108114
message="Prepare release ${STABLE_VERSION}/${UNSTABLE_VERSION}"
109-
branch="opentelemetrybot/prepare-release-${STABLE_VERSION}-${UNSTABLE_VERSION}"
115+
branch="otelbot/prepare-release-${STABLE_VERSION}-${UNSTABLE_VERSION}"
110116
111117
git commit -a -m "$message"
112118
git push origin HEAD:$branch
@@ -196,15 +202,21 @@ jobs:
196202
- name: Use CLA approved github bot
197203
run: .github/scripts/use-cla-approved-github-bot.sh
198204

205+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
206+
id: otelbot-token-main
207+
with:
208+
app-id: ${{ vars.OTELBOT_APP_ID }}
209+
private-key: ${{ secrets.OTELBOT_PRIVATE_KEY }}
210+
199211
- name: Create pull request against main
200212
id: create_main_pr
201213
env:
202214
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
203-
GITHUB_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
215+
GITHUB_TOKEN: ${{ steps.otelbot-token-main.outputs.token }}
204216
run: |
205217
message="Update version to ${STABLE_NEXT_VERSION}/${UNSTABLE_NEXT_VERSION}"
206218
body="Update version to \`${STABLE_NEXT_VERSION}/${UNSTABLE_NEXT_VERSION}\`."
207-
branch="opentelemetrybot/update-version-to-${STABLE_NEXT_VERSION}-${UNSTABLE_NEXT_VERSION}"
219+
branch="otelbot/update-version-to-${STABLE_NEXT_VERSION}-${UNSTABLE_NEXT_VERSION}"
208220
209221
git commit -a -m "$message"
210222
git push origin HEAD:$branch

0 commit comments

Comments
 (0)