Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/gosec.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Gosec
on:
schedule:
- cron: '0 8 * * *'
push:
branches:
- main

permissions:
id-token: write
contents: read

jobs:
tests:
runs-on: ubuntu-latest
env:
GO111MODULE: on
steps:
- name: Get current date
id: date
run: echo "::set-output name=date::$(date +'%Y/%m/%d')"
- name: Checkout Source
uses: actions/checkout@v3
- name: Run Gosec Security Scanner
uses: securego/[email protected]
timeout-minutes: 5
with:
args: --exclude-generated=true --severity=medium --concurrency=1 --fmt json --out=gosec-results.json --stdout --verbose=text --no-fail ./...
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
audience: https://github.com/launchdarkly
role-to-assume: ${{ secrets.ORG_SECURITY_GHA_ROLE_ARN }}
aws-region: us-east-1
- name: Upload scan results to S3
run: |
aws s3 cp ./gosec-results.json s3://launchdarkly-org-security-inventory/scan-results/gosec/${{ steps.date.outputs.date }}/$GITHUB_REPOSITORY.json