Skip to content

feat: implement CI/CD pipeline with linting, testing, release workflows #2

feat: implement CI/CD pipeline with linting, testing, release workflows

feat: implement CI/CD pipeline with linting, testing, release workflows #2

Workflow file for this run

name: CI/CD Pipeline
on:
push:
branches:
- '**'
tags:
- 'v*.*.*'
pull_request:
branches:
- '**'
workflow_dispatch:
jobs:
lint:
uses: ./.github/workflows/ruff.yaml
test:
needs: lint
uses: ./.github/workflows/pytest.yaml
docker:
needs: test
uses: ./.github/workflows/docker-build-and-scan.yaml
with:
DOCKER_PATH_CONTEXT: .
DOCKER_BUILD_DOCKERFILE: ./Dockerfile
DOCKER_TAGS: ${{ github.repository }}:${{ github.sha }}
DOCKER_LOAD_BOOL: false
DOCKER_PUSH_BOOL: ${{ github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v') }}
secrets: inherit
release:

Check failure on line 33 in .github/workflows/ci-cd.yaml

View workflow run for this annotation

GitHub Actions / CI/CD Pipeline

Invalid workflow file

The workflow is not valid. .github/workflows/ci-cd.yaml (Line: 33, Col: 3): Error calling workflow 'milsman2/python-app-template/.github/workflows/release.yaml@9051e8ea680277c97117497b356457d3cdbd8120'. The nested job 'Semantic-Release' is requesting 'contents: write', but is only allowed 'contents: read'.
if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v')
needs: [test, docker]
uses: ./.github/workflows/release.yaml
secrets: inherit