Install Harbor#
-
Add Helm repository:
Add Helm repositoryhelm repo add harbor https://helm.goharbor.io
-
Consider the optimal configuration of Harbor for your particular circumstances - see their docs for more recommendations:
-
We recommend using S3-compatible storage for image blobs (
imageChartStorage
). - We recommend using a managed database service for the Postgres service (
database.type
). -
In high-usage scenarios we recommend using a managed Redis service. (
redis.type
) -
Create the file
harbor-values.yml
inside of your config directory. The proxy-buffering annotations help with large image pushes:harbor-values.ymlexpose: ingress: annotations: kubernetes.io/tls-acme: "true" nginx.ingress.kubernetes.io/proxy-buffering: "off" nginx.ingress.kubernetes.io/proxy-request-buffering: "off" hosts: core: harbor.lagoon.example.com tls: enabled: true certSource: secret secret: secretName: harbor-harbor-ingress externalURL: https://harbor.lagoon.example.com harborAdminPassword: <your Harbor Admin Password> chartmuseum: enabled: false clair: enabled: false notary: enabled: false trivy: enabled: false jobservice: jobLogger: stdout
-
Install Harbor, checking the requirements for the currently supported Harbor versions:
Install Harborhelm upgrade --install --create-namespace \ --namespace harbor --wait \ -f harbor-values.yml \ harbor harbor/harbor
-
Visit Harbor at the URL you set in
harbor.yml
. -
Username: admin
- Password:
Get Harbor secret
kubectl -n harbor get secret harbor-core -o jsonpath="{.data.HARBOR_ADMIN_PASSWORD}" | base64 --decode
- You will need to add the above Harbor credentials to the Lagoon Remote
values.yml
in the next step, as well asharbor-values.yml
.