Skip to content

Commit 963eb76

Browse files
authored
[internal] Update GitHub Actions workflow files (#352)
1 parent 65a0165 commit 963eb76

File tree

7 files changed

+32
-6
lines changed

7 files changed

+32
-6
lines changed

.github/workflows/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ jobs:
362362
SLACK_CHANNEL: provider-upgrade-publish-status
363363
SLACK_COLOR: "#FF0000"
364364
SLACK_ICON_EMOJI: ":taco:"
365-
SLACK_MESSAGE: " Publish failed :x:"
365+
SLACK_MESSAGE: "Publish failed :x:"
366366
SLACK_TITLE: ${{ github.event.repository.name }} upgrade result
367367
SLACK_USERNAME: provider-bot
368368
SLACK_WEBHOOK: ${{ env.SLACK_WEBHOOK_URL }}

.github/workflows/master.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ jobs:
362362
SLACK_CHANNEL: provider-upgrade-publish-status
363363
SLACK_COLOR: "#FF0000"
364364
SLACK_ICON_EMOJI: ":taco:"
365-
SLACK_MESSAGE: " Publish failed :x:"
365+
SLACK_MESSAGE: "Publish failed :x:"
366366
SLACK_TITLE: ${{ github.event.repository.name }} upgrade result
367367
SLACK_USERNAME: provider-bot
368368
SLACK_WEBHOOK: ${{ env.SLACK_WEBHOOK_URL }}

.github/workflows/prerelease.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ jobs:
312312
SLACK_CHANNEL: provider-upgrade-publish-status
313313
SLACK_COLOR: "#FF0000"
314314
SLACK_ICON_EMOJI: ":taco:"
315-
SLACK_MESSAGE: " Publish failed :x:"
315+
SLACK_MESSAGE: "Publish failed :x:"
316316
SLACK_TITLE: ${{ github.event.repository.name }} upgrade result
317317
SLACK_USERNAME: provider-bot
318318
SLACK_WEBHOOK: ${{ env.SLACK_WEBHOOK_URL }}

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ jobs:
324324
SLACK_CHANNEL: provider-upgrade-publish-status
325325
SLACK_COLOR: "#FF0000"
326326
SLACK_ICON_EMOJI: ":taco:"
327-
SLACK_MESSAGE: " Publish failed :x:"
327+
SLACK_MESSAGE: "Publish failed :x:"
328328
SLACK_TITLE: ${{ github.event.repository.name }} upgrade result
329329
SLACK_USERNAME: provider-bot
330330
SLACK_WEBHOOK: ${{ env.SLACK_WEBHOOK_URL }}

.github/workflows/upgrade-provider.yml

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ env:
55
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
66
jobs:
77
upgrade_provider:
8-
if: contains(github.event.issue.title, 'Upgrade terraform-provider-')
8+
if: contains(${{ github.event.issue.title }}, 'Upgrade terraform-provider-')
99
name: upgrade-provider
1010
runs-on: ubuntu-latest
1111
steps:
@@ -14,6 +14,30 @@ jobs:
1414
with:
1515
slack-channel: provider-upgrade-status
1616
slack-webhook: ${{ secrets.SLACK_WEBHOOK_URL }}
17+
- env:
18+
SLACK_CHANNEL: provider-upgrade-publish-status
19+
SLACK_COLOR: "#FF0000"
20+
SLACK_ICON_EMOJI: ":taco:"
21+
SLACK_MESSAGE: >-
22+
Upgrade succeeded :heart_decoration:
23+
24+
PR opened at github.com/pulumi/${{ github.event.repository.name }}/pulls
25+
SLACK_TITLE: ${{ github.event.repository.name }} upgrade result
26+
SLACK_USERNAME: provider-bot
27+
SLACK_WEBHOOK: ${{ env.SLACK_WEBHOOK_URL }}
28+
name: Send Upgrade Success To Slack
29+
uses: rtCamp/action-slack-notify@v2
30+
- env:
31+
SLACK_CHANNEL: provider-upgrade-publish-status
32+
SLACK_COLOR: "#FF0000"
33+
SLACK_ICON_EMOJI: ":taco:"
34+
SLACK_MESSAGE: " Upgrade failed :x:"
35+
SLACK_TITLE: ${{ github.event.repository.name }} upgrade result
36+
SLACK_USERNAME: provider-bot
37+
SLACK_WEBHOOK: ${{ env.SLACK_WEBHOOK_URL }}
38+
if: failure()
39+
name: Send Upgrade Failure To Slack
40+
uses: rtCamp/action-slack-notify@v2
1741
name: Upgrade provider
1842
on:
1943
issues:

.upgrade-config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22

33
---
44
upstream-provider-name: terraform-provider-github
5+
pulumi-infer-version: true
56

scripts/upstream.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,12 @@ start_rebase() {
7979
cd upstream && git fetch
8080

8181
if [ -z "$TO" ]; then
82-
echo '$TO not set, assuming TO is the upstream SHAH currently committed.'
82+
echo '$TO not set, assuming TO is the upstream SHA currently committed.'
8383
else
8484
git checkout "$TO"
8585
fi
8686

87+
git branch -f local
8788
git checkout -B pulumi-patch ${FROM}
8889
git branch --set-upstream-to=local pulumi-patch
8990

0 commit comments

Comments
 (0)