-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaction.yml
More file actions
53 lines (52 loc) · 1.74 KB
/
action.yml
File metadata and controls
53 lines (52 loc) · 1.74 KB
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
name: 'Code Health Check Report'
description: 'Generate Code Health Check Report form an [action-code-health-check](https://github.com/Skywire/action-code-health-check/) run'
inputs:
client-name:
description: 'Client Name for report'
required: true
default: '20.x'
repo-name:
description: 'Client Repository Name'
required: true
run-id:
description: 'Action Run ID containing code health artifacts'
required: true
shared-drive-id:
description: 'Shared Google Drive ID to upload the report'
required: true
google-service-account:
description: 'Service account credentials JSON (stored as a secret)'
required: true
github-token:
description: 'GitHub Token with permission to access the repository and its action runs'
required: true
runs:
using: "composite"
steps:
- uses: actions/checkout@v3
with:
repository: Skywire/action-code-health-report-generator
ref: main
- uses: actions/setup-python@v6
with:
python-version: '3.12'
- name: Export Google Service Account Credentials
env:
GOOGLE_SERVICE_ACCOUNT_KEY: ${{ inputs.google-service-account }}
run: echo "$GOOGLE_SERVICE_ACCOUNT_KEY" > var/credentials/google-service-account.json
shell: bash
- name: Generate Code Health Check Report
env:
GITHUB_TOKEN: ${{ inputs.github-token }}
CLIENT_NAME: ${{ inputs.client-name }}
REPO_NAME: ${{ inputs.repo-name }}
RUN_ID: ${{ inputs.run-id }}
SHARED_DRIVE_ID: ${{ inputs.shared-drive-id }}
shell: bash
run: |
pip install -r requirements.txt
python main.py
- uses: actions/upload-artifact@v4
with:
name: client-report
path: var/output/report.md