flux2: [Gitlab] flux bootstrap fails for personal projects if they already exist
When I try to update my flux v2 installation using the bootstrap command it fails with an error from gitlab:
failed to create project, error: POST https://gitlab.com/api/v4/projects: 400
I use the below bootstrap command to install / update flux v2, which worked until now:
ubuntu@srv1:~$ cat install-flux.sh
curl -s https://toolkit.fluxcd.io/install.sh | sudo bash
export GITLAB_TOKEN=???????????????
flux bootstrap gitlab \
--owner=isnull \
--repository=myrepo \
--branch=master \
--path=k8 \
--token-auth \
--personal
Executing the flux bootstrap yields the error:
ubuntu@srv1:~$ sh install-flux.sh
[INFO] Downloading metadata https://api.github.com/repos/fluxcd/flux2/releases/latest
[INFO] Using 0.7.4 as release
[INFO] Downloading hash https://github.com/fluxcd/flux2/releases/download/v0.7.4/flux_0.7.4_checksums.txt
[INFO] Downloading binary https://github.com/fluxcd/flux2/releases/download/v0.7.4/flux_0.7.4_linux_amd64.tar.gz
[INFO] Verifying binary download
[INFO] Installing flux to /usr/local/bin/flux
► connecting to gitlab.com
✗ failed to create project, error: POST https://gitlab.com/api/v4/projects: 400 {message: {limit_reached: []}, {name: [has already been taken]}, {path: [has already been taken]}}
Sys info:
ubuntu@srv1:~$ flux check
► checking prerequisites
✔ kubectl 1.20.2 >=1.18.0
✔ Kubernetes 1.19.5-34+8af48932a5ef06 >=1.16.0
► checking controllers
✔ source-controller is healthy
► ghcr.io/fluxcd/source-controller:v0.5.6
✔ kustomize-controller is healthy
► ghcr.io/fluxcd/kustomize-controller:v0.5.3
✔ helm-controller is healthy
► ghcr.io/fluxcd/helm-controller:v0.4.4
✔ notification-controller is healthy
► ghcr.io/fluxcd/notification-controller:v0.5.0
✔ all checks passed
Maybe some Gitlab project api change caused this?
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 26 (14 by maintainers)
This should be fixed in flux2 v0.7.7, @IsNull please give it a try.
The finalizers are on the resources themselves, not the flux-system namespace
https://github.com/fluxcd/flux2/discussions/413#discussioncomment-121453
This discussion reference should help, of course you can change it to your
flux-systemnamespace