Skip to content

update requirements.txt #11

update requirements.txt

update requirements.txt #11

Workflow file for this run

name: DevSecOps Workflow
on:
push:
branches: [ main, devsecops ]
pull_request:
branches: [ main, dev ]
jobs:
build:
runs-on: ubuntu-latest
env:
SECRET_KEY: ${{ secrets.SECRET_KEY }}
TEST_DATABASE_PREFIX: test_
services:
postgres:
image: postgres:latest
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: github_actions
ports:
- 5432:5432
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Unit tests and Linters
run: |
# Unit Test
python manage.py test
# Code Formatter
black --check .
# Import sort
isort --check-only .
# Lint Flake8
flake8 .
- name: Test SCA Vulnerabilities | Static Composition Analysis
run: |
pyraider check -f requirements.txt
- name: Check Package License
run: |
pip-licenses --format=json > licenses.json
./scripts/run-license-compliance.sh