File tree Expand file tree Collapse file tree 2 files changed +70
-1
lines changed
Expand file tree Collapse file tree 2 files changed +70
-1
lines changed Original file line number Diff line number Diff line change 1+ name : Fossa
2+
3+ on :
4+ push :
5+ branches :
6+ - master
7+ paths-ignore :
8+ - ' **.md'
9+
10+ jobs :
11+
12+ scan :
13+ name : Fossa
14+ runs-on : ubuntu-20.04
15+ steps :
16+ - name : Checkout Repository
17+ uses : actions/checkout@v2
18+ - name : Scan
19+ uses : fossas/fossa-action@v1
20+ with :
21+ api-key : ${{ secrets.FOSSA_TOKEN }}
22+
23+ notify :
24+ name : Notify
25+ runs-on : ubuntu-20.04
26+ needs : scan
27+ if : always()
28+ steps :
29+ - name : Workflow Status
30+ id : check
31+ uses : martialonline/workflow-status@v2
32+ - name : Output Variables
33+ id : commit
34+ run : |
35+ echo "::set-output name=sha::$(echo ${GITHUB_SHA} | cut -c1-7)"
36+ echo "::set-output name=repo::$(echo ${GITHUB_REPOSITORY} | cut -d '/' -f 2)"
37+ - name : Send Notification
38+ uses : 8398a7/action-slack@v3
39+ if : steps.check.outputs.status == 'failure'
40+ with :
41+ status : custom
42+ custom_payload : |
43+ {
44+ username: 'Fossa Scan',
45+ icon_emoji: ':fossa:',
46+ mention: 'channel',
47+ attachments: [{
48+ title: '${{ steps.commit.outputs.repo }} ${{ github.workflow }} license scan has failed',
49+ color: 'danger',
50+ fields: [{
51+ title: 'Commit Hash',
52+ value: '${{ steps.commit.outputs.sha }}',
53+ short: true
54+ },
55+ {
56+ title: 'Author',
57+ value: '${{ github.actor }}',
58+ short: true
59+ },
60+ {
61+ title: 'Job URL',
62+ value: 'https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}',
63+ short: false
64+ }]
65+ }]
66+ }
67+ env :
68+ GITHUB_TOKEN : ${{ github.token }}
69+ SLACK_WEBHOOK_URL : ${{ secrets.SLACK_WEBHOOK }}
Original file line number Diff line number Diff line change 11
2- [ ![ Continuous Integration] ( https://github.com/nginxinc/nginx-plus-go-client/workflows/Continuous%20Integration/badge.svg )] ( https://github.com/nginxinc/nginx-plus-go-client/actions ) [ ![ License] ( https://img.shields.io/badge/License-Apache%202.0-blue.svg )] ( https://opensource.org/licenses/Apache-2.0 ) [ ![ Go Report Card] ( https://goreportcard.com/badge/github.com/nginxinc/nginx-plus-go-client )] ( https://goreportcard.com/report/github.com/nginxinc/nginx-plus-go-client )
2+ [ ![ Continuous Integration] ( https://github.com/nginxinc/nginx-plus-go-client/workflows/Continuous%20Integration/badge.svg )] ( https://github.com/nginxinc/nginx-plus-go-client/actions ) [ ![ License] ( https://img.shields.io/badge/License-Apache%202.0-blue.svg )] ( https://opensource.org/licenses/Apache-2.0 ) [ ![ Go Report Card] ( https://goreportcard.com/badge/github.com/nginxinc/nginx-plus-go-client )] ( https://goreportcard.com/report/github.com/nginxinc/nginx-plus-go-client ) [ ![ FOSSA Status ] ( https://app.fossa.io/api/projects/custom%2B1062%2Fgithub.com%2Fnginxinc%2Fnginx-plus-go-client.svg?type=shield )] ( https://app.fossa.io/projects/custom%2B1062%2Fgithub.com%2Fnginxinc%2Fnginx-plus-go-client?ref=badge_shield )
33
44# NGINX Plus Go Client
55
You can’t perform that action at this time.
0 commit comments