Skip to content

Commit

Permalink
Enable Cargo Audit on the CI
Browse files Browse the repository at this point in the history
  • Loading branch information
tatsuya6502 committed Jun 18, 2022
1 parent a7808f3 commit 3b053bf
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 2 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/Audit.yml
@@ -0,0 +1,47 @@
name: Cargo Audit

on:
push:
paths:
- '**/Cargo.toml'
- '**/Cargo.lock'
schedule:
# https://crontab.guru/
- cron: '5 20 * * 5'

jobs:
audit:
runs-on: ubuntu-latest
steps:
- name: Checkout Moka
uses: actions/checkout@v2

- name: Install Rust toolchain (Nightly)
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
override: true

- uses: Swatinem/rust-cache@v1

- name: cargo clean
uses: actions-rs/cargo@v1
with:
command: clean

- name: Check for known security vulnerabilities (Latest versions)
uses: actions-rs/audit-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}

- name: Downgrade dependencies to minimal versions
uses: actions-rs/cargo@v1
with:
command: update
args: -Z minimal-versions

- name: Check for known security vulnerabilities (Minimal versions)
uses: actions-rs/audit-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/CI.yml
Expand Up @@ -13,7 +13,7 @@ on:
- '.vscode/**'
schedule:
# Run against the last commit on the default branch on Friday at 8pm (UTC?)
- cron: '0 20 * * 5'
- cron: '0 20 * * 5'

jobs:
test:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/CIQuantaDisabled.yml
Expand Up @@ -13,7 +13,7 @@ on:
- '.vscode/**'
schedule:
# Run against the last commit on the default branch on Friday at 8pm (UTC?)
- cron: '0 20 * * 5'
- cron: '0 20 * * 5'

jobs:
test:
Expand Down

0 comments on commit 3b053bf

Please sign in to comment.