feat: Commit initial
This commit is contained in:
commit
40dc0f4184
43 changed files with 1990 additions and 0 deletions
43
kubernetes/flux-system/README.md
Normal file
43
kubernetes/flux-system/README.md
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
# FluxCD System Configuration
|
||||
|
||||
This directory contains FluxCD configuration for GitOps.
|
||||
|
||||
## Setup
|
||||
|
||||
1. **Install FluxCD** (done automatically by Ansible):
|
||||
```bash
|
||||
flux install --namespace=flux-system
|
||||
```
|
||||
|
||||
2. **Create Forgejo credentials secret**:
|
||||
```bash
|
||||
kubectl create secret generic forgejo-credentials \
|
||||
--namespace=flux-system \
|
||||
--from-literal=username=git \
|
||||
--from-literal=password=YOUR_FORGEJO_TOKEN
|
||||
```
|
||||
|
||||
3. **Update GitRepository URL** in `gotk-sync.yaml`:
|
||||
```yaml
|
||||
url: https://forgejo.your-domain.com/your-org/infra.git
|
||||
```
|
||||
|
||||
4. **Apply FluxCD configuration**:
|
||||
```bash
|
||||
kubectl apply -k kubernetes/flux-system/
|
||||
```
|
||||
|
||||
## Monitoring
|
||||
|
||||
Check FluxCD status:
|
||||
```bash
|
||||
flux get sources git
|
||||
flux get kustomizations
|
||||
flux logs
|
||||
```
|
||||
|
||||
Force reconciliation:
|
||||
```bash
|
||||
flux reconcile source git infra-repo
|
||||
flux reconcile kustomization apps --with-source
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue