Skip to main content

Pipeline scaffold

Creates the three template workflows in a new repository, already wired to the team's publishing role.

Run it once, in a new repository. It writes the three template workflows, the panlabs.toml and the Python pipeline file, and opens the pull request.

# .github/workflows/scaffold.yml
# Run once, via `workflow_dispatch`, and delete this file afterwards.
name: scaffold
on:
workflow_dispatch:
inputs:
equipe:
description: "the team slug, as it appears in the IAM role"
required: true
linguagem:
description: "python | terraform"
required: true
default: python

permissions:
contents: write
pull-requests: write
id-token: write

jobs:
scaffold:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Write the pipeline
uses: panlabs/scaffold-de-esteira@v3
with:
equipe: ${{ inputs.equipe }}
linguagem: ${{ inputs.linguagem }}
# the role is derived from the team, and the skill rejects a value
# that does not match `papel-<equipe>-esteira-<ambiente>`
papel-publicacao: papel-${{ inputs.equipe }}-esteira-prd

- name: Open the pull request
uses: peter-evans/create-pull-request@v6
with:
branch: esteira/scaffold
title: "pipeline: the three template workflows"
body: |
Generated by `panlabs/scaffold-de-esteira@v3`.

- `verificar.yml`: tests, typing, formatting and scanning on every PR
- `publicar.yml`: build, signing and publishing on `main`
- `inventario.yml`: weekly record of image provenance

`esteira.py` is the source; the YAML is generated. See
https://panlabs.interno/en/ferramentas/bibliotecas/overpower/visao-geral
delete-branch: true

The skill refuses to run in a repository that already has workflows: adopting it in an existing project is the procedure in Install, and it is two pull requests for a reason the skill has no way to judge.