Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/piomin/kubernetes-config-argocd
Kubernetes YAML manifests in configuration repository managed by Argo CD
https://github.com/piomin/kubernetes-config-argocd
argocd argocd-applicationsets gitops helm kubernetes vcluster
Last synced: 2 months ago
JSON representation
Kubernetes YAML manifests in configuration repository managed by Argo CD
- Host: GitHub
- URL: https://github.com/piomin/kubernetes-config-argocd
- Owner: piomin
- Created: 2023-06-28T11:00:04.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2024-05-13T12:32:58.000Z (8 months ago)
- Last Synced: 2024-10-10T20:55:11.247Z (3 months ago)
- Topics: argocd, argocd-applicationsets, gitops, helm, kubernetes, vcluster
- Homepage: https://piotrminkowski.com
- Size: 38.1 KB
- Stars: 16
- Watchers: 2
- Forks: 15
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Kubernetes GitOps Configuration Example with Argo CD [![Twitter](https://img.shields.io/twitter/follow/piotr_minkowski.svg?style=social&logo=twitter&label=Follow%20Me)](https://twitter.com/piotr_minkowski)
Here's the current structure of the repo (will be modified soon):
```shell
├── apps
│ └── cert-manager
│ ├── secrets.yaml
│ ├── certificates.yaml
│ └── cluster-issuer.yaml
└── bootstrap
├── Chart.yaml
├── templates
│ ├── cert-manager.yaml
│ ├── postgresql.yaml
│ ├── projects.yaml
│ ├── vault.yaml
│ └── vault-config-operator.yaml
└── values.yaml
```For now, it shows how to install and use in the GitOps way:
1. [cert-manager](https://cert-manager.io/) via Helm chartFor more information you can refer to the articles:
1. [Testing GitOps on Virtual Kubernetes Clusters with ArgoCD](https://piotrminkowski.com/2023/06/29/testing-gitops-on-virtual-kubernetes-clusters-with-argocd/)## Getting Started
You can test the configuration on the virtual Kubernetes cluster using the [vcluster](https://www.vcluster.com/) tool. In order to that create the ArgoCD `ApplicationSet` based on the cluster generator:
```yaml
apiVersion: argoproj.io/v1alpha1
kind: ApplicationSet
metadata:
name: config
namespace: argocd
spec:
generators:
- clusters: # (1)
selector:
matchLabels:
argocd.argoproj.io/secret-type: cluster
template:
metadata:
name: '{{name}}-config-test'
spec:
destination:
namespace: argocd
server: https://kubernetes.default.svc
project: default
source:
helm:
parameters:
- name: server
value: '{{server}}'
- name: project
value: '{{metadata.labels.loft.sh/vcluster-instance-name}}'
path: bootstrap
repoURL: https://github.com/piomin/kubernetes-config-argocd.git
targetRevision: '{{metadata.labels.loft.sh/vcluster-instance-name}}'
syncPolicy:
automated: {}
syncOptions:
- CreateNamespace=true
```If you just want to test on the single cluster managed by ArgoCD you can create the following ArgoCD `Application`:
```yaml
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: config
namespace: argocd
spec:
destination:
namespace: argocd
server: https://kubernetes.default.svc
project: default
source:
path: bootstrap
repoURL: https://github.com/piomin/kubernetes-config-argocd.git
targetRevision: HEAD
syncPolicy:
automated: {}
syncOptions:
- CreateNamespace=true
```