天天看点

cloud-native 版本的gitlab安装一半时中断,后该如何再次安装

背景

在使用 helm 安装cloud native 版本的 gitlab 时候,有时候会中间终端操作,然后再次执行时,会报下面的错误

$  helm upgrade xxx gitlab-1.0.2/gitlab -f gitlab-1.0.2-values-ce.yaml
2018/10/11 16:30:58 warning: destination for global is a table. Ignoring non-table value <nil>
2018/10/11 16:30:58 warning: destination for global is a table. Ignoring non-table value <nil>
Error: UPGRADE FAILED: serviceaccounts "xxx-shared-secrets" already exists
           

解决问题

执行下面的命令删除相关的内容,再次安装即可解决问题

kubectl delete sa xxx-shared-secrets --namespace yyy
kubectl delete role xxx-shared-secrets --namespace yyy
kubectl delete rolebindings xxx-shared-secrets --namespace yyy
kubectl delete configmap xxx-shared-secrets --namespace yyy