Mabe this is how flux works?

This commit is contained in:
Julius 2022-05-22 14:55:33 +02:00
parent 7ef72afc56
commit 1c281c672e
Signed by: j00lz
GPG key ID: AF241B0AA237BBA2
7 changed files with 67 additions and 19 deletions

View file

@ -0,0 +1,4 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- test

View file

@ -0,0 +1,16 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: whoami-deployment-ingress
spec:
rules:
- host: "whoami.asraphiel.dev"
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: whoami-deployment-service
port:
number: 80

View file

@ -0,0 +1,5 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- pain.yaml
- gotk-sync.yaml

View file

@ -0,0 +1,25 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: whoami-deployment
labels:
app: whoami-deployment
keel.sh/policy: force
keel.sh/match-tag: "true"
spec:
replicas: 1
selector:
matchLabels:
app: whoami-deployment
template:
metadata:
labels:
app: whoami-deployment
spec:
containers:
- name: whoami-deployment
imagePullPolicy: Always
image: traefik/whoami
ports:
- containerPort: 80

View file

@ -0,0 +1,11 @@
apiVersion: v1
kind: Service
metadata:
name: whoami-deployment-service
spec:
selector:
app: whoami-deployment
ports:
- protocol: TCP
port: 80
targetPort: 80

View file

@ -1,15 +1,14 @@
---
apiVersion: kustomize.toolkit.fluxcd.io/v1beta2
kind: Kustomization
metadata:
name: podinfo
name: apps
namespace: flux-system
spec:
interval: 5m0s
path: ./kustomize
interval: 10m0s
dependsOn:
- name: core
path: ./flux/cluster/apps
prune: true
sourceRef:
kind: GitRepository
name: podinfo
targetNamespace: default
name: flux-system

View file

@ -1,12 +0,0 @@
---
apiVersion: source.toolkit.fluxcd.io/v1beta2
kind: GitRepository
metadata:
name: podinfo
namespace: flux-system
spec:
interval: 30s
ref:
branch: master
url: https://github.com/stefanprodan/podinfo