-
Notifications
You must be signed in to change notification settings - Fork 1
62 lines (54 loc) · 2.21 KB
/
renovate.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
on:
workflow_dispatch:
schedule:
# every day at 2:30AM
- cron: "30 14 * * *"
name: Renovate
jobs:
check_dependencies:
name: Check dependencies
runs-on: ubuntu-22.04
steps:
- name: GitHub App token
id: get_token
uses: tibdex/[email protected]
with:
private_key: ${{ secrets.RENOVATE_KEY }}
app_id: ${{ secrets.RENOVATE_APP_ID }}
- uses: actions/checkout@v4
- name: Set up Git credential helper and add Cloudsmith credentials
run: |
git config --global credential.helper store
echo "https://${{ secrets.ROSALIND_CLOUDSMITH_USERNAME }}:${{ secrets.ROSALIND_CLOUDSMITH_API }}@dl.cloudsmith.io" > ~/.git-credentials
shell: bash
- name: Run Self-hosted Renovate
run: |
cd renovate && npm ci && npm run renovate -- --token ${{ steps.get_token.outputs.token }}
shell: bash
- name: Set if main BRANCH_NAME
if: failure() && github.ref == 'refs/heads/main'
shell: bash
run: echo "BRANCH_NAME=main" >> "$GITHUB_ENV"
- name: Set if pull_request BRANCH_NAME
if: failure() && contains(fromJSON('["pull_request", "pull_request_target"]'), github.event_name)
shell: bash
run: echo "BRANCH_NAME=${{ github.head_ref }}" >> "$GITHUB_ENV"
- name: Send GitHub Action trigger data to Slack workflow
id: slack
if: failure()
uses: slackapi/[email protected]
with:
payload: |
{
"actor": "${{ github.actor }}",
"workflow": "${{ github.workflow }}",
"event_name": "${{ github.event_name }}",
"run_attempt": "${{ github.run_attempt }}",
"ref": "${{ github.ref }}",
"branch_name": "${{ env.BRANCH_NAME }}",
"repository": "${{ github.repository }}",
"repository_url": "https://github.com/${{ github.repository }}",
"workflow_run_url": "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
}
env:
SLACK_WEBHOOK_URL: https://hooks.slack.com/triggers/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