Skip to content

Github workflows 🤖

This repository serves as a centralized location for reusable GitHub workflows. By defining shared workflows here, we streamline the process of maintaining consistency and quality across all repositories.

This repository contains reusable GitHub workflows intended to be referenced from other repositories via the uses: owner/repo/.github/workflows/<file>@<ref> mechanism.

How to reference these workflows

In your repository, use a uses: reference under jobs to call a reusable workflow.

Example:

yaml
jobs:
  example:
    uses: this-is-tobi/github-workflows/.github/workflows/scan-sonarqube.yml@main
    with:
      SONAR_URL: 'https://sonarqube.example.com'
    secrets:
      SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
      SONAR_PROJECT_KEY: ${{ secrets.SONAR_PROJECT_KEY }}

Using Reusable Workflows from Private Repositories

You can use reusable workflows from a private repository, but there are important requirements and limitations:

  • Repository Access: Both the caller and the reusable workflow repository must be internal to the same user / organization.
  • Reference Format: Always reference the reusable workflow using the full path: owner/repo/.github/workflows/workflow.yml@ref.

For more details, see:

Available workflows