-
Notifications
You must be signed in to change notification settings - Fork 766
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
harbor-registry with F5 BIG-IP ingress does not work when docker push images (unauthorized to access repository) #513
Comments
value.yaml [svcapp_su@ddp-deveco-master01 harbor-helm]$ cat values.yaml Set the way how to expose the service. Set the type as "ingress","clusterIP", "nodePort" or "loadBalancer" and fill the informationin the corresponding sectiontype: ingress The external URL for Harbor core service. It is used to1) populate the docker/helm commands showed on portal2) populate the token service URL returned to docker/notary clientFormat: protocol://domain[:port]. Usually:1) if "expose.type" is "ingress", the "domain" should bethe value of "expose.ingress.hosts.core"2) if "expose.type" is "clusterIP", the "domain" should bethe value of "expose.clusterIP.name"3) if "expose.type" is "nodePort", the "domain" should bethe IP address of k8s nodeIf Harbor is deployed behind the proxy, set it as the URL of proxyexternalURL: https://core.skt.ai The persistence is enabled by default and a default StorageClassis needed in the k8s cluster to provision volumes dynamicly.Specify another StorageClass in the "storageClass" or set "existingClaim"if you have already existing persistent volumes to useFor storing images and charts, you can also use "azure", "gcs", "s3","swift" or "oss". Set it in the "imageChartStorage" sectionpersistence: Setting it to "keep" to avoid removing PVCs during a helm deleteoperation. Leaving it empty will delete PVCs after the chart deletedresourcePolicy: "" Define which storage backend is used for registry and chartmuseum to storeimages and charts. Refer tohttps://github.com/docker/distribution/blob/master/docs/configuration.md#storagefor the detail.imageChartStorage:
imagePullPolicy: IfNotPresent Use this set to assign a list of default pullSecretsimagePullSecrets: - name: docker-registry-secret- name: internal-registry-secretThe update strategy for deployments with persistent volumes(jobservice, registryand chartmuseum): "RollingUpdate" or "Recreate"Set it as "Recreate" when "RWM" for volumes isn't supportedupdateStrategy: debug, info, warning, error or fatallogLevel: info The initial password of Harbor admin. Change it from portal after launching HarborharborAdminPassword: "Harbor12345" The secret key used for encryption. Must be a string of 16 chars.secretKey: "not-a-secure-key" The proxy settings for updating clair vulnerabilities from the Internet and replicatingartifacts from/to the registries that cannot be reached directlyproxy: UAA Authentication OptionsIf you're using UAA for authentication behind a self-signedcertificate you will need to provide the CA Cert.Set uaaSecretName below to provide a pre-created secret thatcontains a base64 encoded CA Certificate named
|
I ran into the same issue with a nginx ingress controller yesterday. I was working with "dev" tag for all the images on my values.yaml. I moved to a stable release, basically git checkout v1.2.4, changed the values.yaml to fit my needs and it works well now. |
after you edited values "tag: dev" to "tag: stable", i did same work on my values.yaml, but it was not work... |
This issue is being marked stale due to a period of inactivity. If this issue is still relevant, please comment or remove the stale label. Otherwise, this issue will close in 30 days. |
This issue was closed because it has been stalled for 30 days with no activity. If this issue is still relevant, please re-open a new issue. |
i set up harbor-registry with F5 BIG-IP ingress controller.
using harbor-helm branch: master, latest version
and results... clean installed
and harbor portal is working well
login is good and creating project is good
but...docker client have trouble with docker login and push images
when i try to docker login harbor registory, docker client show TLS handshake time out error
so i edit my docker daemon.json files to add insecure registries
"insecure-registries": ["core.skt.ai"]
and next try, docker client show http://core.skt.ai to https://core.skt.ai/service?token ... error
so i edit realm http://core.skt.ai in harbor registry configmap (https --> http)
then i finally login to harbor registry with admin & password
the real problem is here...
when i tried to push my local images, it send me such errors...
[svcapp_su@ddp-deveco-gpu01 ~]$ sudo docker push core.skt.ai/deveco/nginx:1.17
The push refers to repository [core.skt.ai/deveco/nginx]
22439467ad99: Preparing
b4a29beac87c: Preparing
488dfecc21b1: Preparing
unauthorized: unauthorized to access repository: deveco/nginx, action: push
i wonder how to solve this problem...
harbor core give me such errors
2020-02-19T09:01:30Z [ERROR] [/server/registry/error/error.go:25]: failed to handle the request POST /v2/deveco/nginx/blobs/uploads/: unauthorized to access repository: deveco/nginx, action: push, UNAUTHORIZED, unauthorized to access repository: deveco/nginx, action: push
2020/02/19 09:01:30.447 [D] [transaction.go:70] | 172.27.15.196| 401 | 2.550614ms| match| POST /v2/deveco/nginx/blobs/uploads/ r:/*
2020-02-19T09:01:30Z [ERROR] [/server/registry/error/error.go:25]: failed to handle the request POST /v2/deveco/nginx/blobs/uploads/: unauthorized to access repository: deveco/nginx, action: push, UNAUTHORIZED, unauthorized to access repository: deveco/nginx, action: push
2020/02/19 09:01:30.447 [D] [transaction.go:70] | 172.27.15.196| 401 | 2.852277ms| match| POST /v2/deveco/nginx/blobs/uploads/ r:/*
2020-02-19T09:01:30Z [ERROR] [/server/registry/error/error.go:25]: failed to handle the request POST /v2/deveco/nginx/blobs/uploads/: unauthorized to access repository: deveco/nginx, action: push, UNAUTHORIZED, unauthorized to access repository: deveco/nginx, action: push
2020/02/19 09:01:30.448 [D] [transaction.go:70] | 172.27.15.196| 401 | 2.902966ms| match| POST /v2/deveco/nginx/blobs/uploads/ r:/*
this is my harbor-helm value.yaml files
[svcapp_su@ddp-deveco-master01 logging]$ kubectl get pod -n harbor-helm
NAME READY STATUS RESTARTS AGE
harbor-harbor-chartmuseum-7cd84fdfc9-8shkv 1/1 Running 3 31h
harbor-harbor-clair-69cfc88854-brjfp 2/2 Running 7 31h
harbor-harbor-core-86c547987-7vf24 1/1 Running 5 31h
harbor-harbor-database-0 1/1 Running 2 31h
harbor-harbor-jobservice-79fc59d6c-jvcrz 1/1 Running 4 31h
harbor-harbor-notary-server-8d55f5847-5rbnd 1/1 Running 3 31h
harbor-harbor-notary-signer-6648c6ddbc-8wj22 1/1 Running 2 31h
harbor-harbor-portal-67c6b747f-b6kjm 1/1 Running 3 31h
harbor-harbor-redis-0 1/1 Running 3 31h
harbor-harbor-registry-84bbd9869f-55snb 2/2 Running 4 30h
[svcapp_su@ddp-deveco-master01 logging]$ kubectl get svc -n harbor-helm
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
harbor-harbor-chartmuseum ClusterIP 10.233.33.237 80/TCP 31h
harbor-harbor-clair ClusterIP 10.233.58.2 8080/TCP 31h
harbor-harbor-core ClusterIP 10.233.55.246 80/TCP 31h
harbor-harbor-database ClusterIP 10.233.13.10 5432/TCP 31h
harbor-harbor-jobservice ClusterIP 10.233.43.45 80/TCP 31h
harbor-harbor-notary-server ClusterIP 10.233.24.244 4443/TCP 31h
harbor-harbor-notary-signer ClusterIP 10.233.14.74 7899/TCP 31h
harbor-harbor-portal ClusterIP 10.233.33.136 80/TCP 31h
harbor-harbor-redis ClusterIP 10.233.33.101 6379/TCP 31h
harbor-harbor-registry ClusterIP 10.233.57.155 5000/TCP,8080/TCP 31h
[svcapp_su@ddp-deveco-master01 harbor-helm]$ kubectl get ing -n harbor-helm
NAME HOSTS ADDRESS PORTS AGE
harbor-harbor-ingress core.skt.ai,notary.skt.ai 172.27.15.242 80, 443 31h
The text was updated successfully, but these errors were encountered: