CodeQL Scan Service-1 #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will trigger only when a file in the service-1 directory is edited. | |
# | |
# Make note of the following lines: | |
# 11 and 15: this tells the action when to run | |
# 41 and 42: This is the command to only build service 1 | |
# 48: This is the category. THIS IS SUPER IMPORTANT. If you don't edit the category | |
# the results will be overwritten when other services/directories are scanned | |
# | |
name: "CodeQL Scan Service-1" | |
on: | |
push: | |
branches: [ "main" ] | |
paths: | |
- 'service-1/**' | |
pull_request: | |
branches: [ "main" ] | |
paths: | |
- 'service-1/**' | |
schedule: | |
- cron: '31 2 * * 2' | |
jobs: | |
analyze: | |
name: Analyze | |
runs-on: 'ubuntu-latest' | |
timeout-minutes: 360 | |
permissions: | |
actions: read | |
contents: read | |
security-events: write | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
# Initializes the CodeQL tools for scanning. | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v2 | |
with: | |
languages: "go" | |
- name: build-service-1 | |
run: go build service-1/*.go | |
- name: Perform CodeQL Analysis | |
uses: github/codeql-action/analyze@v2 | |
with: | |
category: "service-1" |