ci: move gitleaks to component

This commit is contained in:
Simon Cornet 2026-01-19 17:16:43 +01:00
commit b4380c7954
2 changed files with 3 additions and 25 deletions

View file

@ -1,17 +1,13 @@
--- ---
# gitLab ci stages # gitlab stages
stages: stages:
- "gitleaks" - "gitleaks"
- "linting" - "linting"
# include jobs # include components
include: include:
# code plumbing
- local: ".gitlab/gitleaks.yaml"
# linting
- component: "$CI_SERVER_FQDN/components/ansible/linting@v3.0.3" - component: "$CI_SERVER_FQDN/components/ansible/linting@v3.0.3"
- component: "$CI_SERVER_FQDN/components/gitleaks/gitleaks@v1.0.0"
- component: "$CI_SERVER_FQDN/components/markdownlint/markdownlint@1.0.0" - component: "$CI_SERVER_FQDN/components/markdownlint/markdownlint@1.0.0"
- component: "$CI_SERVER_FQDN/components/yamllint/yamllint@1.0.2" - component: "$CI_SERVER_FQDN/components/yamllint/yamllint@1.0.2"

View file

@ -1,18 +0,0 @@
---
# gitleaks
gitleaks:
stage: "gitleaks"
image:
name: "ghcr.io/gitleaks/gitleaks:latest"
variables:
GIT_DEPTH: 1
rules:
# run only on push to default branch
- if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH'
- when: "never"
# start linting
script:
- "gitleaks detect --source . --verbose --redact"