diff --git a/README.md b/README.md index 72574c5..ca15bb3 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ To do this, execute the following patch command: ```bash oc -n openshift-gitops patch argocds.argoproj.io openshift-gitops \ --type merge \ - --patch '{"spec":{"sourceNamespaces":["openshift-gitops","example-application-basic","example-application-basic-servicemesh","example-application-progressive","example-application-helm-basic","example-application-helm-progressive"]}}' + --patch '{"spec":{"sourceNamespaces":["openshift-gitops","example-application-basic","example-application-basic-servicemesh","example-application-progressive","example-application-helm-basic","example-application-helm-progressive","hcp-operators"]}}' ``` The `openshift-gitops` namespace is the `default` namespace and might not be necessary to add to the `sourceNamespaces` list. However, it is added here for completeness. diff --git a/management_project.yaml b/management_project.yaml index 69c28a5..3c612ba 100644 --- a/management_project.yaml +++ b/management_project.yaml @@ -23,6 +23,9 @@ spec: - name: in-cluster namespace: example-application-progressive server: https://kubernetes.default.svc + - name: in-cluster + namespace: hcp-operators + server: https://kubernetes.default.svc - name: in-cluster namespace: example-application-helm-progressive server: https://kubernetes.default.svc diff --git a/ocp/deployments/helm_hcp_namespace.yaml b/ocp/deployments/helm_hcp_namespace.yaml new file mode 100644 index 0000000..c3cf313 --- /dev/null +++ b/ocp/deployments/helm_hcp_namespace.yaml @@ -0,0 +1,14 @@ +apiVersion: v1 +kind: Namespace +metadata: + annotations: + openshift.io/description: "" + openshift.io/display-name: "" + openshift.io/requester: kubeadmin + #openshift.io/sa.scc.mcs: s0:c26,c20 + #openshift.io/sa.scc.supplemental-groups: 65535/10000 + #openshift.io/sa.scc.uid-range: 65535/10000 + argocd.argoproj.io/sync-wave: "-1" + labels: + argocd.argoproj.io/managed-by: openshift-gitops + name: hcp-operators diff --git a/ocp/deployments/helm_hcp_project.yaml b/ocp/deployments/helm_hcp_project.yaml new file mode 100644 index 0000000..6812cf7 --- /dev/null +++ b/ocp/deployments/helm_hcp_project.yaml @@ -0,0 +1,21 @@ +apiVersion: argoproj.io/v1alpha1 +kind: AppProject +metadata: + name: hashicorp + labels: + argocd.argoproj.io/sync-wave: "0" +spec: + sourceNamespaces: + - openshift-gitops + clusterResourceWhitelist: + - group: '*' + kind: '*' + destinations: + - name: in-cluster + namespace: openshift-gitops + server: https://kubernetes.default.svc + namespaceResourceWhitelist: + - group: '*' + kind: '*' + sourceRepos: + - git@github.com:leonsteinhaeuser/rh-ocp-examples.git diff --git a/ocp/deployments/helm_hcp_vault.yaml b/ocp/deployments/helm_hcp_vault.yaml new file mode 100644 index 0000000..3c8a1eb --- /dev/null +++ b/ocp/deployments/helm_hcp_vault.yaml @@ -0,0 +1,48 @@ +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: hcp-vault + namespace: &ns hcp-operators + labels: + argocd.argoproj.io/sync-wave: "-1" +spec: + destination: + namespace: *ns + server: https://kubernetes.default.svc + project: hashicorp + source: + chart: vault + repoURL: https://helm.releases.hashicorp.com + targetRevision: 0.29.1 + helm: + releaseName: hcp-vault + valuesObject: + global: + openshift: true + injector: + image: + repository: "registry.connect.redhat.com/hashicorp/vault-k8s" + tag: "1.5.0-ubi" + agentImage: + repository: "registry.connect.redhat.com/hashicorp/vault" + tag: "1.18.1-ubi" + server: + image: + repository: "registry.connect.redhat.com/hashicorp/vault" + tag: "1.18.1-ubi" + readinessProbe: + path: "/v1/sys/health?uninitcode=204" + syncPolicy: + automated: + prune: true + selfHeal: true + retry: + backoff: + duration: 5s + factor: 2 + maxDuration: 3m0s + limit: 5 + syncOptions: + - PruneLast=true + - ApplyOutOfSyncOnly=true + - ServerSideApply=true