From a9546b16adc9dc834e0664d6c5f3ed350d3f5511 Mon Sep 17 00:00:00 2001 From: Arthur BOUDREAULT Date: Thu, 6 Nov 2025 17:33:14 +0100 Subject: [PATCH] docs: update README to clarify requirements for MGCI_API_TOKEN --- README-fr.md | 8 +++++++- README.md | 9 ++++++++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/README-fr.md b/README-fr.md index 00a6488..0058bd5 100644 --- a/README-fr.md +++ b/README-fr.md @@ -75,7 +75,12 @@ Chaque fonctionnalité testée peut être activée avec une variable `MGCI_TEST_ ##### MGCI_API_TOKEN -Pour que l'ensemble des jobs fonctionne, un token doit avoir été généré sur votre instance Gitlab. Il peut s'agir d'un _project access token_, _personal access token_ ou _group access token_. Il doit avoir un accès `Owner` et doit avoir les scopes `api`, `create_runner` et `manage_runner`. +Pour que l'ensemble des jobs fonctionne, un token doit avoir été généré sur votre instance Gitlab. D'après nos tests : + +- un _personal access token_ issu d'un compte administrateur avec les scopes `api`, `create_runner`, `manage_runner` fonctionne ; +- les _project access token_ et _group access token_ (même avec `api`, `create_runner`, `manage_runner`) ne permettent pas d'exécuter tous les tests (notamment `runners:tags`). + +⚠️ Le job `runners:tags` s'appuie sur l'API administrateur (`GET /runners/all`). Utilisez donc impérativement un personal access token créé depuis un compte disposant des droits administrateur sur l'instance GitLab, sinon vous obtiendrez l'erreur `jq: Cannot index string with string "id"`. Vous devrez ensuite le renseigner dans la variable `MGCI_API_TOKEN` dans les variables de la CI. ## Mises à jour du projet @@ -163,6 +168,7 @@ fonction: Pour améliorer la fiabilité et la performance de notre pipeline CI/CD, nous avons ajouté une authentification Docker Hub. Cette modification permet de : + - Éviter les limitations de pulls d'images de Docker Hub pour les utilisateurs anonymes. - Améliorer la stabilité des jobs. diff --git a/README.md b/README.md index 762386d..362f2dc 100644 --- a/README.md +++ b/README.md @@ -75,7 +75,13 @@ Each tested feature can be activated with a `MGCI_TEST_` variable that ##### MGCI_API_TOKEN -For all jobs to work, a token must have been generated on your Gitlab instance. It can be a _project access token_, _personal access token_ or _group access token_. It must have Owner access and must have the `api`, `create_runner` and `manage_runner` scopes. +For all jobs to work, a token must have been generated on your Gitlab instance. From our tests: + +- a personal access token issued from an administrator account with scopes `api`, `create_runner`, `manage_runner` works; +- project access tokens and group access tokens (even with `api`, `create_runner`, `manage_runner`) cannot run every test, especially `runners:tags`. + +⚠️ The `runners:tags` job relies on the administrator API (`GET /runners/all`). Use a personal access token created by an administrator, otherwise you will receive the error `jq: Cannot index string with string "id"`. + You will then need to enter it in the `MGCI_API_TOKEN` variable in the CI variables. ## Updating the Project @@ -163,6 +169,7 @@ function: To improve the reliability and performance of our CI/CD pipeline, we have added Docker Hub authentication. This modification allows: + - Avoiding Docker Hub image pull rate limits for unauthenticated users. - Improving job stability. -- GitLab