File tree Expand file tree Collapse file tree 3 files changed +63
-127
lines changed
Expand file tree Collapse file tree 3 files changed +63
-127
lines changed Original file line number Diff line number Diff line change @@ -244,61 +244,32 @@ jobs:
244244
245245 steps :
246246 - name : Notify Slack
247- uses : slackapi/slack-github-action@v1.27 .0
247+ uses : slackapi/slack-github-action@v2.0 .0
248248 with :
249- channel-id : ${{ secrets.SLACK_CHANNEL_ID }}
249+ method : chat.postMessage
250+ token : ${{ secrets.SLACK_BOT_TOKEN }}
250251 payload : |
251- {
252- "blocks": [
253- {
254- "type": "section",
255- "text": {
256- "type": "mrkdwn",
257- "text": ":rocket: *${{ github.workflow }} Completed in: ${{ github.repository }}* :white_check_mark:"
258- }
259- },
260- {
261- "type": "divider"
262- },
263- {
264- "type": "section",
265- "fields": [
266- {
267- "type": "mrkdwn",
268- "text": "*Build Result:*\n${{ needs.integration_tests.result == 'success' && ':large_green_circle: Build Passed' || ':red_circle: Build Failed' }}"
269- },
270- {
271- "type": "mrkdwn",
272- "text": "*Branch:*\n`${{ github.ref_name }}`"
273- }
274- ]
275- },
276- {
277- "type": "section",
278- "fields": [
279- {
280- "type": "mrkdwn",
281- "text": "*Commit Hash:*\n<${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|${{ github.sha }}>"
282- },
283- {
284- "type": "mrkdwn",
285- "text": "*Run URL:*\n<${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View Run Details>"
286- }
287- ]
288- },
289- {
290- "type": "divider"
291- },
292- {
293- "type": "context",
294- "elements": [
295- {
296- "type": "mrkdwn",
297- "text": "Triggered by: :bust_in_silhouette: `${{ github.actor }}`"
298- }
299- ]
300- }
301- ]
302- }
303- env :
304- SLACK_BOT_TOKEN : ${{ secrets.SLACK_BOT_TOKEN }}
252+ channel: ${{ secrets.SLACK_CHANNEL_ID }}
253+ blocks:
254+ - type: section
255+ text:
256+ type: mrkdwn
257+ text: ":rocket: *${{ github.workflow }} Completed in: ${{ github.repository }}* :white_check_mark:"
258+ - type: divider
259+ - type: section
260+ fields:
261+ - type: mrkdwn
262+ text: "*Build Result:*\n${{ needs.integration_tests.result == 'success' && ':large_green_circle: Build Passed' || ':red_circle: Build Failed' }}"
263+ - type: mrkdwn
264+ text: "*Branch:*\n`${{ github.ref_name }}`"
265+ - type: section
266+ fields:
267+ - type: mrkdwn
268+ text: "*Commit Hash:*\n<${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|${{ github.sha }}>"
269+ - type: mrkdwn
270+ text: "*Run URL:*\n<${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View Run Details>"
271+ - type: divider
272+ - type: context
273+ elements:
274+ - type: mrkdwn
275+ text: "Triggered by: :bust_in_silhouette: `${{ github.actor }}`"
Original file line number Diff line number Diff line change @@ -46,61 +46,32 @@ jobs:
4646
4747 - name : Notify Slack
4848 if : always() && github.repository == 'linode/linode-cli' # Run even if integration tests fail and only on main repository
49- uses : slackapi/slack-github-action@v1.26 .0
49+ uses : slackapi/slack-github-action@v2.0 .0
5050 with :
51- channel-id : ${{ secrets.SLACK_CHANNEL_ID }}
51+ method : chat.postMessage
52+ token : ${{ secrets.SLACK_BOT_TOKEN }}
5253 payload : |
53- {
54- "blocks": [
55- {
56- "type": "section",
57- "text": {
58- "type": "mrkdwn",
59- "text": ":rocket: *${{ github.workflow }} Completed in: ${{ github.repository }}* :white_check_mark:"
60- }
61- },
62- {
63- "type": "divider"
64- },
65- {
66- "type": "section",
67- "fields": [
68- {
69- "type": "mrkdwn",
70- "text": "*Build Result:*\n${{ steps.smoke_tests.outcome == 'success' && ':large_green_circle: Build Passed' || ':red_circle: Build Failed' }}"
71- },
72- {
73- "type": "mrkdwn",
74- "text": "*Branch:*\n`${{ github.ref_name }}`"
75- }
76- ]
77- },
78- {
79- "type": "section",
80- "fields": [
81- {
82- "type": "mrkdwn",
83- "text": "*Commit Hash:*\n<${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|${{ github.sha }}>"
84- },
85- {
86- "type": "mrkdwn",
87- "text": "*Run URL:*\n<${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View Run Details>"
88- }
89- ]
90- },
91- {
92- "type": "divider"
93- },
94- {
95- "type": "context",
96- "elements": [
97- {
98- "type": "mrkdwn",
99- "text": "Triggered by: :bust_in_silhouette: `${{ github.actor }}`"
100- }
101- ]
102- }
103- ]
104- }
105- env :
106- SLACK_BOT_TOKEN : ${{ secrets.SLACK_BOT_TOKEN }}
54+ channel: ${{ secrets.SLACK_CHANNEL_ID }}
55+ blocks:
56+ - type: section
57+ text:
58+ type: mrkdwn
59+ text: ":rocket: *${{ github.workflow }} Completed in: ${{ github.repository }}* :white_check_mark:"
60+ - type: divider
61+ - type: section
62+ fields:
63+ - type: mrkdwn
64+ text: "*Build Result:*\n${{ steps.smoke_tests.outcome == 'success' && ':large_green_circle: Build Passed' || ':red_circle: Build Failed' }}"
65+ - type: mrkdwn
66+ text: "*Branch:*\n`${{ github.ref_name }}`"
67+ - type: section
68+ fields:
69+ - type: mrkdwn
70+ text: "*Commit Hash:*\n<${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|${{ github.sha }}>"
71+ - type: mrkdwn
72+ text: "*Run URL:*\n<${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View Run Details>"
73+ - type: divider
74+ - type: context
75+ elements:
76+ - type: mrkdwn
77+ text: "Triggered by: :bust_in_silhouette: `${{ github.actor }}`"
Original file line number Diff line number Diff line change @@ -11,20 +11,14 @@ jobs:
1111 steps :
1212 - name : Notify Slack - Main Message
1313 id : main_message
14- uses : slackapi/slack-github-action@v1.27 .0
14+ uses : slackapi/slack-github-action@v2.0 .0
1515 with :
16- channel-id : ${{ secrets.CLI_SLACK_CHANNEL_ID }}
16+ method : chat.postMessage
17+ token : ${{ secrets.SLACK_BOT_TOKEN }}
1718 payload : |
18- {
19- "blocks": [
20- {
21- "type": "section",
22- "text": {
23- "type": "mrkdwn",
24- "text": "*New Release Published: _linode-cli_ <${{ github.event.release.html_url }}|${{ github.event.release.tag_name }}> is now live!* :tada:"
25- }
26- }
27- ]
28- }
29- env :
30- SLACK_BOT_TOKEN : ${{ secrets.SLACK_BOT_TOKEN }}
19+ channel: ${{ secrets.CLI_SLACK_CHANNEL_ID }}
20+ blocks:
21+ - type: section
22+ text:
23+ type: mrkdwn
24+ text: "*New Release Published: _linode-cli_ <${{ github.event.release.html_url }}|${{ github.event.release.tag_name }}> is now live!* :tada:"
You can’t perform that action at this time.
0 commit comments