diff --git a/apps/whoami/deployment.yaml b/apps/whoami/deployment.yaml new file mode 100644 index 0000000..a0596b7 --- /dev/null +++ b/apps/whoami/deployment.yaml @@ -0,0 +1,23 @@ +kind: Deployment +apiVersion: apps/v1 +metadata: + name: whoami + labels: + app: whoami + +spec: + replicas: 1 + selector: + matchLabels: + app: whoami + template: + metadata: + labels: + app: whoami + spec: + containers: + - name: whoami + image: traefik/whoami + ports: + - name: web + containerPort: 80 \ No newline at end of file diff --git a/apps/whoami/ingress.yaml b/apps/whoami/ingress.yaml new file mode 100644 index 0000000..7ce9d44 --- /dev/null +++ b/apps/whoami/ingress.yaml @@ -0,0 +1,15 @@ +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: whoami-ingress +spec: + rules: + - http: + paths: + - path: / + pathType: Prefix + backend: + service: + name: whoami + port: + name: web \ No newline at end of file diff --git a/apps/whoami/kustomization.yaml b/apps/whoami/kustomization.yaml new file mode 100644 index 0000000..be4aed4 --- /dev/null +++ b/apps/whoami/kustomization.yaml @@ -0,0 +1,6 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +resources: +- deployment.yaml +- service.yaml +- ingress.yaml \ No newline at end of file diff --git a/apps/whoami/service.yaml b/apps/whoami/service.yaml new file mode 100644 index 0000000..6773de2 --- /dev/null +++ b/apps/whoami/service.yaml @@ -0,0 +1,13 @@ +apiVersion: v1 +kind: Service +metadata: + name: whoami + +spec: + ports: + - name: web + port: 80 + targetPort: web + + selector: + app: whoami \ No newline at end of file diff --git a/clusters/talos/apps.yaml b/clusters/talos/apps.yaml index e69de29..c1a0a1f 100644 --- a/clusters/talos/apps.yaml +++ b/clusters/talos/apps.yaml @@ -0,0 +1,15 @@ +apiVersion: kustomize.toolkit.fluxcd.io/v1 +kind: Kustomization +metadata: + name: apps + namespace: flux-system +spec: + interval: 1h + retryInterval: 1m + timeout: 5m + sourceRef: + kind: GitRepository + name: flux-system + path: ./apps + prune: true + wait: true \ No newline at end of file