cicd
auth_error
ai_generated
true
错误:注册令牌已过期。请在 GitLab 管理区域生成新的注册令牌。
ERROR: Registration token is expired. Please generate a new registration token on the GitLab admin area.
ID: cicd/gitlab-ci-runner-registration-token-expired
92%修复率
84%置信度
1证据数
2024-04-05首次发现
版本兼容性
| 版本 | 状态 | 引入 | 弃用 | 备注 |
|---|---|---|---|---|
| GitLab 16.8 | active | — | — | — |
| GitLab Runner 16.7.0 | active | — | — | — |
根因分析
用于注册运行器的 GitLab Runner 注册令牌已过期,通常是由于令牌轮换策略或在 GitLab 设置中手动撤销。
English
The GitLab Runner registration token used to register the runner has expired, typically due to a token rotation policy or manual revocation in GitLab settings.
官方文档
https://docs.gitlab.com/runner/register/解决方案
-
Generate a new registration token from GitLab admin area: go to Admin > CI/CD > Runners, click 'Register a runner', copy the new token. Then re-register the runner: `sudo gitlab-runner unregister --name my-runner && sudo gitlab-runner register --url https://gitlab.com --registration-token NEW_TOKEN --non-interactive --executor docker --description my-runner`.
-
If using GitLab CI/CD variables, update the `CI_REGISTRATION_TOKEN` variable in the project or group settings with the new token, then trigger a pipeline that re-registers the runner automatically.
无效尝试
常见但无效的做法:
-
95% 失败
The token is stored in the runner's config.toml and is expired on the server side; restarting does not refresh it.
-
80% 失败
Manually editing the token without proper registration can cause authentication failures; GitLab expects the token to be generated and associated with a specific runner.