Deploy openshift gitops

This commit is contained in:
2025-04-18 23:25:36 -05:00
parent 0f26afd794
commit 0b22970bad
11 changed files with 137 additions and 5 deletions

View File

@@ -0,0 +1,26 @@
---
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: cluster-applications
namespace: openshift-gitops
spec:
destination:
name: in-cluster
namespace: openshift-gitops
project: default
source:
path: cluster
repoURL: git@github.com:rblundon/homelab.git
targetRevision: HEAD
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- RespectIgnoreDifferences=true
ignoreDifferences:
- group: argoproj.io
kind: Application
jsonPointers:
- /spec/syncPolicy/automated

View File

@@ -0,0 +1,15 @@
---
apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfig
metadata:
labels:
machineconfiguration.openshift.io/role: master
name: 99-master-custom-enable-iscsid
spec:
config:
ignition:
version: 3.1.0
systemd:
units:
- enabled: true
name: iscsid.service

View File

@@ -0,0 +1,15 @@
---
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
commonLabels:
cluster: hub.int.mk-labs.cloud
resources:
- namespace.yaml
- operatorgroup.yaml
- subscription.yaml
- rbac.yaml
# - argocd.yaml
- app-of-apps.yaml
- enable-iscsi.yaml

View File

@@ -0,0 +1,7 @@
---
apiVersion: v1
kind: Namespace
metadata:
labels:
argocd.argoproj.io/managed-by: openshift-gitops-operator
name: openshift-gitops-operator

View File

@@ -0,0 +1,8 @@
---
apiVersion: operators.coreos.com/v1
kind: OperatorGroup
metadata:
name: openshift-gitops-operator
namespace: openshift-gitops-operator
spec:
upgradeStrategy: Default

View File

@@ -0,0 +1,37 @@
---
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: openshift-gitops-admin
subjects:
- kind: ServiceAccount
name: gitops-service-cluster
namespace: openshift-gitops
- kind: ServiceAccount
name: openshift-gitops-applicationset-controller
namespace: openshift-gitops
- kind: ServiceAccount
name: openshift-gitops-argocd-application-controller
namespace: openshift-gitops
- kind: ServiceAccount
name: openshift-gitops-argocd-dex-server
namespace: openshift-gitops
- kind: ServiceAccount
name: openshift-gitops-argocd-grafana
namespace: openshift-gitops
- kind: ServiceAccount
name: openshift-gitops-argocd-redis
namespace: openshift-gitops
- kind: ServiceAccount
name: openshift-gitops-argocd-redis-ha
namespace: openshift-gitops
- kind: ServiceAccount
name: openshift-gitops-argocd-server
namespace: openshift-gitops
- kind: ServiceAccount
name: openshift-gitops-operator-controller-manager
namespace: openshift-operators
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: cluster-admin

View File

@@ -0,0 +1,16 @@
---
apiVersion: operators.coreos.com/v1alpha1
kind: Subscription
metadata:
name: openshift-gitops-operator
namespace: openshift-gitops-operator
spec:
channel: gitops-1.16
config:
env:
- name: ARGOCD_CLUSTER_CONFIG_NAMESPACES
value: openshift-gitops
installPlanApproval: Automatic
name: openshift-gitops-operator
source: redhat-operators
sourceNamespace: openshift-marketplace