From 83eba555bac1dc7cc62771185cc2d36bc67a94bc Mon Sep 17 00:00:00 2001 From: "Benguria Elguezabal, Gorka" <gorka.benguria@tecnalia.com> Date: Tue, 21 May 2024 18:21:08 +0200 Subject: [PATCH] adapts to tecnalia --- .gitlab-ci.yml | 34 ++++++++++++++++++-------------- README.md | 2 ++ kicker.json | 14 +++++++++++++ templates/gitlab-ci-renovate.yml | 10 ++++++++++ 4 files changed, 45 insertions(+), 15 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 3bce0e7..bd76525 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,19 +1,23 @@ include: - - project: 'to-be-continuous/tools/gitlab-ci' - ref: 'master' - file: '/templates/extract.yml' - - project: 'to-be-continuous/tools/gitlab-ci' - ref: 'master' - file: '/templates/validation.yml' - - project: 'to-be-continuous/kicker' - ref: 'master' - file: '/templates/validation.yml' - - project: 'to-be-continuous/bash' - ref: '3.4' - file: '/templates/gitlab-ci-bash.yml' - - project: 'to-be-continuous/semantic-release' - ref: '3.8' - file: '/templates/gitlab-ci-semrel.yml' + - component: git.code.tecnalia.com/smartdatalab/public/ci-cd-components/gitlab-ci/extract@master + inputs: + extract-script-job-tags: ["docker"] + - component: git.code.tecnalia.com/smartdatalab/public/ci-cd-components/gitlab-ci/validation@master + inputs: + check-links-job-tags: ["docker"] + tbc-check-job-tags: ["docker"] + tbc-check-image: cicd-docker-dev.artifact.tecnalia.com/tbc-check:master + gitlab-ci-lint-job-tags: ["docker"] + - component: git.code.tecnalia.com/smartdatalab/public/ci-cd-components/kicker/validation@master + inputs: + kicker-validation-job-tags: ["docker"] + schema-base-url: "https://git.code.tecnalia.com/api/v4/projects/smartdatalab%2Fpublic%2Fci-cd-components%2Fkicker/repository/files" + - component: git.code.tecnalia.com/smartdatalab/public/ci-cd-components/bash/gitlab-ci-bash@master + inputs: + bash-shellcheck-job-tags: ["docker"] + - component: git.code.tecnalia.com/smartdatalab/public/ci-cd-components/semantic-release/gitlab-ci-semrel@master + inputs: + semantic-release-job-tags: ["docker"] stages: - build diff --git a/README.md b/README.md index aab43a9..6fd4fd2 100644 --- a/README.md +++ b/README.md @@ -39,6 +39,8 @@ The Renovate template uses some global configuration used throughout all jobs. | `platform` / `RENOVATE_PLATFORM` | The Platform type of repository [See doc](https://docs.renovatebot.com/self-hosted-configuration/#platform) | `gitlab` | | :lock: `RENOVATE_TOKEN`| A GitLab access token to allow Renovate crawl your projects. [See doc](https://docs.renovatebot.com/modules/platform/gitlab/#authentication) | _none_ | | :lock: `GITHUB_COM_TOKEN`| A GitHub access token to allow Renovate fetch changelogs. [See doc](https://docs.renovatebot.com/getting-started/running/#githubcom-token-for-changelogs) | _none_ | +| `renovate-validator-job-tags` / `RENOVATE_VALIDATOR_JOB_TAGS` | Tags to be used for selecting runners for the job | `[]` | +| `renovate-depcheck-job-tags` / `RENOVATE_DEPCHECK_JOB_TAGS` | Tags to be used for selecting runners for the job | `[]` | This template will help you using [Renovate](https://www.mend.io/renovate/) from a GitLab project to automate your dependency updates within your groups or projects. diff --git a/kicker.json b/kicker.json index 9676a4b..50f983c 100644 --- a/kicker.json +++ b/kicker.json @@ -25,6 +25,20 @@ "name": "RENOVATE_PLATFORM", "description": "The Platform type of repository", "default": "gitlab" + }, + { + "name": "RENOVATE_RENOVATE_VALIDATOR_JOB_TAGS", + "description": "Tags to be used for selecting runners for the job", + "type": "array", + "default": [], + "advanced": true + }, + { + "name": "RENOVATE_RENOVATE_DEPCHECK_JOB_TAGS", + "description": "Tags to be used for selecting runners for the job", + "type": "array", + "default": [], + "advanced": true } ] } diff --git a/templates/gitlab-ci-renovate.yml b/templates/gitlab-ci-renovate.yml index 3b72ce4..2f6228f 100644 --- a/templates/gitlab-ci-renovate.yml +++ b/templates/gitlab-ci-renovate.yml @@ -22,6 +22,14 @@ spec: platform: description: The Platform type of repository default: gitlab + renovate-validator-job-tags: + description: tags to filter applicable runners for renovate-validator job + default: [] + type: array + renovate-depcheck-job-tags: + description: tags to filter applicable runners for renovate-depcheck job + default: [] + type: array --- workflow: rules: @@ -255,6 +263,7 @@ renovate-validator: dependencies: [] script: - renovate-config-validator + tags: $[[ inputs.renovate-validator-job-tags ]] # dependency check job: on manual or schedule (dry-run otherwise) renovate-depcheck: @@ -278,3 +287,4 @@ renovate-depcheck: variables: RENOVATE_DRY_RUN: "false" - if: $RENOVATE_TOKEN + tags: $[[ inputs.renovate-depcheck-job-tags ]] -- GitLab