← harnesscd-example-apps

gitops yaml

39e9485dfed050eba480c8e7c95a82096eb27fd8 · OP (oppenheimer) · Sep 13, 2023 17:44

+45 · 3 files changed

  • guestbook/harness-gitops/application.yml +23 −0
  • guestbook/harness-gitops/cluster.yml +11 −0
  • guestbook/harness-gitops/repository.yml +11 −0
diff --git a/guestbook/harness-gitops/application.yml b/guestbook/harness-gitops/application.yml
new file mode 100644
index 0000000..e87f0ee
--- /dev/null
+++ b/guestbook/harness-gitops/application.yml
@@ -0,0 +1,23 @@
+gitops:
+  name: gitops-application
+  projectIdentifier: default_project
+  orgIdentifier: default
+  type: application
+  application:
+    metadata:
+      namespace: default
+      clusterName: gitops_cluster
+      labels:
+        harness.io/serviceRef: harnessguestbook
+        harness.io/envRef: harnessdevenv
+    spec:
+      source:
+        repoURL: https://github.com/harness-community/harnesscd-example-apps
+        path: guestbook
+        targetRevision: master
+      destination:
+        server: https://kubernetes.default.svc
+        namespace: default
+  agentIdentifier: AGENT_NAME
+  clusterIdentifier: gitopscluster
+  repoIdentifier: gitopsrepo
\ No newline at end of file
diff --git a/guestbook/harness-gitops/cluster.yml b/guestbook/harness-gitops/cluster.yml
new file mode 100644
index 0000000..8638b84
--- /dev/null
+++ b/guestbook/harness-gitops/cluster.yml
@@ -0,0 +1,11 @@
+gitops:
+  name: gitops_cluster
+  identifier: gitopscluster
+  projectIdentifier: default_project
+  orgIdentifier: default
+  type: cluster
+  cluster:
+    server: https://kubernetes.default.svc
+    config:
+      clusterConnectionType: IN_CLUSTER
+  agentIdentifier: AGENT_NAME
\ No newline at end of file
diff --git a/guestbook/harness-gitops/repository.yml b/guestbook/harness-gitops/repository.yml
new file mode 100644
index 0000000..04ab77f
--- /dev/null
+++ b/guestbook/harness-gitops/repository.yml
@@ -0,0 +1,11 @@
+gitops:
+    name: gitops_repo
+    identifier: gitopsrepo
+    projectIdentifier: default_project
+    orgIdentifier: default
+    type: repository
+    repo:
+        repo: https://github.com/harness-community/harnesscd-example-apps
+        type: git
+        connectionType: HTTPS_ANONYMOUS
+    agentIdentifier: AGENT_NAME
\ No newline at end of file