Skip to main content
Version: Next

Requirements

Before using GitHub Action Reusable Workflows, ensure your project and environment meet the following requirements:

Repository Requirementsโ€‹

  • GitHub Repository: Your project must be hosted on GitHub
  • GitHub Actions Enabled: GitHub Actions must be enabled for your repository
  • Workflow Permissions: Appropriate permissions to create and modify workflow files

Project Requirementsโ€‹

For Python Projectsโ€‹

  • Python Version: Python 3.8 or higher (workflows support 3.8-3.12)
  • Package Structure:
    • Standard Python package with setup.py or pyproject.toml
    • Poetry-managed projects with pyproject.toml and poetry.lock
  • Test Framework: PyTest (recommended and supported by default)
  • Version File: __pkg_info__.py module with __version__ variable (for deployment workflows)

For Docker Projectsโ€‹

  • Dockerfile: A valid Dockerfile in your repository
  • Docker Registry Access: Credentials for DockerHub or GitHub Container Registry (GHCR)

For Documentation Projectsโ€‹

  • Documentation Framework: Docusaurus, MkDocs, or similar
  • Build Configuration: Proper build scripts defined in package.json or documentation config

Optional Requirementsโ€‹

For Code Coverageโ€‹

  • Coverage Tools: pytest-cov or coverage.py
  • Platform Tokens:
    • Codecov token (for Codecov integration)
    • Coveralls token (for Coveralls integration)
    • Codacy project token (for Codacy integration)

For Code Qualityโ€‹

  • SonarQube/SonarCloud: Account and project token for code quality scanning
  • Configuration File: sonar-project.properties in repository root

For Release Managementโ€‹

  • GitHub Token: Automatically provided by GitHub Actions
  • PyPI Credentials: Username and token for publishing to PyPI (official or test)
  • Semantic Versioning: Follow semantic versioning for releases

GitHub Secrets Configurationโ€‹

You'll need to configure the following secrets in your repository settings:

Required for PyPI Deploymentโ€‹

  • PYPI_USERNAME or PYPI_TOKEN - PyPI credentials
  • TEST_PYPI_TOKEN - Test PyPI token (for testing releases)

Required for Code Coverageโ€‹

  • CODECOV_TOKEN - Codecov API token
  • COVERALLS_TOKEN - Coveralls API token
  • CODACY_PROJECT_TOKEN - Codacy project token

Required for Dockerโ€‹

  • DOCKERHUB_USERNAME - DockerHub username
  • DOCKERHUB_TOKEN - DockerHub access token

Required for SonarQubeโ€‹

  • SONAR_TOKEN - SonarQube/SonarCloud token