Skip to content

Commit

Permalink
feat: add harbor cosi hr (#3053)
Browse files Browse the repository at this point in the history
Co-authored-by: Tarun Gupta Akirala <[email protected]>
  • Loading branch information
2 people authored and ArvinderPal09 committed Jan 30, 2025
1 parent 9fa1277 commit 28935cb
Show file tree
Hide file tree
Showing 8 changed files with 88 additions and 0 deletions.
28 changes: 28 additions & 0 deletions services/harbor/1.16.0/cosi-storage.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: harbor-cosi-storage
namespace: ${releaseNamespace}
spec:
force: false
prune: true
wait: true
interval: 6h
retryInterval: 1m
path: ./services/harbor/1.16.0/cosi-storage
dependsOn:
- name: ncr-system-namespace
sourceRef:
kind: GitRepository
name: management
namespace: kommander-flux
timeout: 1m
postBuild:
substituteFrom:
- kind: ConfigMap
name: substitution-vars
healthChecks:
- apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
name: harbor-cosi-storage
namespace: ${releaseNamespace}
35 changes: 35 additions & 0 deletions services/harbor/1.16.0/cosi-storage/cosi-bucket.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
---
apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
metadata:
name: harbor-cosi-storage
namespace: ${releaseNamespace}
spec:
chart:
spec:
chart: cosi-bucket-kit
sourceRef:
kind: HelmRepository
name: mesosphere.github.io-charts-stable
namespace: kommander-flux
version: 0.0.1-alpha.1
interval: 15s
install:
crds: CreateReplace
remediation:
retries: 30
createNamespace: true
upgrade:
crds: CreateReplace
remediation:
retries: 30
releaseName: harbor-cosi-storage
targetNamespace: ncr-system
valuesFrom:
- kind: ConfigMap
name: harbor-1.16.0-d2iq-defaults
valuesKey: harbor-cosi-values.yaml
optional: true
- kind: ConfigMap
name: harbor-overrides
optional: true
4 changes: 4 additions & 0 deletions services/harbor/1.16.0/cosi-storage/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- cosi-bucket.yaml
12 changes: 12 additions & 0 deletions services/harbor/1.16.0/defaults/harbor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,5 +76,17 @@ data:
imageChartStorage:
type: filesystem
disableredirect: true
externalURL: https://${ingressAddress:=harbor}:5000
harbor-cosi-values.yaml: |
---
cosiBucketKit:
enabled: false
transformations:
priorityClassName: dkp-high-priority
kubectlImage: ${kubetoolsImageRepository:=bitnami/kubectl}:${kubetoolsImageTag:=1.31.4}
harbor:
enabled: true
cmName: harbor-cosi-overrides
cmNamespace: ${releaseNamespace}
1 change: 1 addition & 0 deletions services/harbor/1.16.0/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- release.yaml
- cosi-storage.yaml
- ncr-system-namespace.yaml
- pre-install.yaml
- database.yaml
Expand Down
4 changes: 4 additions & 0 deletions services/harbor/1.16.0/pre-install/secrets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,15 @@ kind: Secret
metadata:
name: harbor-admin-password
namespace: ncr-system
annotations:
kustomize.toolkit.fluxcd.io/ssa: Merge
type: Opaque
---
apiVersion: v1
kind: Secret
metadata:
name: harbor-valkey-password
namespace: ncr-system
annotations:
kustomize.toolkit.fluxcd.io/ssa: Merge
type: Opaque
1 change: 1 addition & 0 deletions services/harbor/1.16.0/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ spec:
- name: harbor-pre-install
- name: harbor-database
- name: harbor-valkey
- name: harbor-cosi-storage
sourceRef:
kind: GitRepository
name: management
Expand Down
3 changes: 3 additions & 0 deletions services/harbor/1.16.0/release/harbor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ spec:
valuesFrom:
- kind: ConfigMap
name: harbor-1.16.0-d2iq-defaults
- kind: ConfigMap
name: harbor-cosi-overrides
optional: true
- kind: ConfigMap
name: harbor-overrides
optional: true
Expand Down

0 comments on commit 28935cb

Please sign in to comment.