From 52ea1d79fe455d34e363b87ff558da84e0a343af Mon Sep 17 00:00:00 2001 From: Khue Doan Date: Mon, 23 Aug 2021 00:08:08 +0700 Subject: [PATCH] Remove old apps layer --- apps/Makefile | 12 ---- apps/README.md | 1 - apps/kustomization.yaml | 20 ------- apps/resources/cloudflared.yaml | 25 -------- apps/resources/drone-runner-kube.yaml | 27 --------- apps/resources/drone.yaml | 35 ------------ apps/resources/keycloak.yaml | 30 ---------- apps/resources/kured.yaml | 21 ------- apps/resources/metallb.yaml | 31 ---------- apps/resources/nginx.yaml | 23 -------- apps/resources/node-problem-detector.yaml | 21 ------- apps/resources/prometheus.yaml | 23 -------- apps/resources/template.yaml | 21 ------- apps/resources/tunnel.yaml | 69 ----------------------- apps/resources/vault.yaml | 23 -------- apps/resources/wireguard.yaml | 32 ----------- 16 files changed, 414 deletions(-) delete mode 100644 apps/Makefile delete mode 100644 apps/README.md delete mode 100644 apps/kustomization.yaml delete mode 100644 apps/resources/cloudflared.yaml delete mode 100644 apps/resources/drone-runner-kube.yaml delete mode 100644 apps/resources/drone.yaml delete mode 100644 apps/resources/keycloak.yaml delete mode 100644 apps/resources/kured.yaml delete mode 100644 apps/resources/metallb.yaml delete mode 100644 apps/resources/nginx.yaml delete mode 100644 apps/resources/node-problem-detector.yaml delete mode 100644 apps/resources/prometheus.yaml delete mode 100644 apps/resources/template.yaml delete mode 100644 apps/resources/tunnel.yaml delete mode 100644 apps/resources/vault.yaml delete mode 100644 apps/resources/wireguard.yaml diff --git a/apps/Makefile b/apps/Makefile deleted file mode 100644 index 893bd012..00000000 --- a/apps/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -.POSIX: -.EXPORT_ALL_VARIABLES: - -KUBECONFIG = ../cluster/kubeconfig.yaml - -default: apply - -apply: - kubectl apply --kustomize . - -destroy: - kubectl delete --kustomize . diff --git a/apps/README.md b/apps/README.md deleted file mode 100644 index e7bd82dd..00000000 --- a/apps/README.md +++ /dev/null @@ -1 +0,0 @@ -# Self-hosted applications diff --git a/apps/kustomization.yaml b/apps/kustomization.yaml deleted file mode 100644 index 22b15b55..00000000 --- a/apps/kustomization.yaml +++ /dev/null @@ -1,20 +0,0 @@ -apiVersion: kustomize.config.k8s.io/v1beta1 -kind: Kustomization - -resources: -# System -- resources/descheduler.yaml -- resources/kured.yaml -- resources/node-problem-detector.yaml -- resources/prometheus.yaml -- resources/cloudflared.yaml -# Operation -# - resources/vault.yaml -- resources/drone.yaml -- resources/drone-runner-kube.yaml -# - resources/keycloak.yaml -# Applications -- resources/gitea.yaml -# - resources/wireguard.yaml - -namespace: argocd diff --git a/apps/resources/cloudflared.yaml b/apps/resources/cloudflared.yaml deleted file mode 100644 index b5105ae8..00000000 --- a/apps/resources/cloudflared.yaml +++ /dev/null @@ -1,25 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: cloudflared - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: cloudflared - source: - repoURL: https://khuedoan.github.io/charts - chart: cloudflared - targetRevision: 0.1.1 - helm: - parameters: - - name: replicaCount - value: '3' - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true diff --git a/apps/resources/drone-runner-kube.yaml b/apps/resources/drone-runner-kube.yaml deleted file mode 100644 index d5048dab..00000000 --- a/apps/resources/drone-runner-kube.yaml +++ /dev/null @@ -1,27 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: drone-runner-kube - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: drone - source: - repoURL: https://charts.drone.io - chart: drone-runner-kube - targetRevision: 0.1.5 - helm: - parameters: - - name: 'rbac.buildNamespaces[0]' - value: drone - - name: env.DRONE_NAMESPACE_DEFAULT - value: drone - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true diff --git a/apps/resources/drone.yaml b/apps/resources/drone.yaml deleted file mode 100644 index 0fa282ec..00000000 --- a/apps/resources/drone.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: drone - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: drone - source: - repoURL: https://charts.drone.io - chart: drone - targetRevision: 0.1.7 - helm: - parameters: - - name: env.DRONE_SERVER_HOST - value: drone.khuedoan.com - - name: env.DRONE_SERVER_PROTO - value: https - - name: env.DRONE_GITEA_SERVER - value: https://git.khuedoan.com - - name: 'ingress.enabled' - value: 'true' - - name: 'ingress.hosts[0].host' - value: drone.khuedoan.com - - name: 'ingress.hosts[0].paths[0]' - value: '/' - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true diff --git a/apps/resources/keycloak.yaml b/apps/resources/keycloak.yaml deleted file mode 100644 index b1d927b8..00000000 --- a/apps/resources/keycloak.yaml +++ /dev/null @@ -1,30 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: keycloak - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: keycloak - source: - repoURL: https://charts.bitnami.com/bitnami - chart: keycloak - targetRevision: 4.1.3 - helm: - values: | - ingress: - enabled: true - hostname: keycloak.khuedoan.com - proxyAddressForwarding: false # TODO Fix ingress proxy - auth: - adminUser: admin - adminPassword: "thisisfortesting" # TODO Fix Keycloak password - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true diff --git a/apps/resources/kured.yaml b/apps/resources/kured.yaml deleted file mode 100644 index d3a95a6b..00000000 --- a/apps/resources/kured.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: kured - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: kube-system - server: '' - source: - path: '' - repoURL: 'https://weaveworks.github.io/kured' - targetRevision: 2.6.0 - chart: kured - project: default - syncPolicy: - automated: - prune: true - selfHeal: true diff --git a/apps/resources/metallb.yaml b/apps/resources/metallb.yaml deleted file mode 100644 index 51e2f534..00000000 --- a/apps/resources/metallb.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: metallb - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: kube-system - server: '' - source: - path: '' - repoURL: 'https://charts.bitnami.com/bitnami' - targetRevision: 2.3.5 - chart: metallb - helm: - parameters: - - name: 'configInline' - value: | - address-pools: - - name: default - protocol: layer2 - addresses: - # TODO (optimize) Use metal values for MetalLB values - - 192.168.1.150-192.168.1.180 - project: default - syncPolicy: - automated: - prune: true - selfHeal: true diff --git a/apps/resources/nginx.yaml b/apps/resources/nginx.yaml deleted file mode 100644 index 18ec42fd..00000000 --- a/apps/resources/nginx.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: ingress-nginx - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: kube-system - server: '' - source: - path: '' - repoURL: 'https://kubernetes.github.io/ingress-nginx' - targetRevision: 3.35.0 - chart: ingress-nginx - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true diff --git a/apps/resources/node-problem-detector.yaml b/apps/resources/node-problem-detector.yaml deleted file mode 100644 index fa44dde1..00000000 --- a/apps/resources/node-problem-detector.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: node-problem-detector - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: kube-system - server: '' - source: - path: '' - repoURL: 'https://charts.deliveryhero.io/' - targetRevision: 2.0.2 - chart: node-problem-detector - project: default - syncPolicy: - automated: - prune: true - selfHeal: true diff --git a/apps/resources/prometheus.yaml b/apps/resources/prometheus.yaml deleted file mode 100644 index 43159775..00000000 --- a/apps/resources/prometheus.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: prometheus - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: monitoring-system - server: '' - source: - path: '' - repoURL: 'https://prometheus-community.github.io/helm-charts' - targetRevision: 15.1.1 - chart: kube-prometheus-stack - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true diff --git a/apps/resources/template.yaml b/apps/resources/template.yaml deleted file mode 100644 index 16b621f6..00000000 --- a/apps/resources/template.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: CHARTNAME -spec: - destination: - name: in-cluster - namespace: NAMESPACE - server: '' - source: - path: '' - repoURL: 'CHARTREPO' - targetRevision: CHARTVERSION - chart: CHARTNAME - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true diff --git a/apps/resources/tunnel.yaml b/apps/resources/tunnel.yaml deleted file mode 100644 index feb7a85b..00000000 --- a/apps/resources/tunnel.yaml +++ /dev/null @@ -1,69 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: cloudflared -spec: - selector: - matchLabels: - app: cloudflared - replicas: 3 - template: - metadata: - labels: - app: cloudflared - spec: - containers: - - name: cloudflared - image: cloudflare/cloudflared:2021.4.0 - args: - - tunnel - - --config - - /etc/cloudflared/config/config.yaml - - run - livenessProbe: - httpGet: - path: /ready - port: 2000 - failureThreshold: 1 - initialDelaySeconds: 10 - periodSeconds: 10 - volumeMounts: - - name: config - mountPath: /etc/cloudflared/config - readOnly: true - - name: certs - mountPath: /etc/cloudflared - readOnly: true - - name: creds - mountPath: /etc/cloudflared/creds - readOnly: true - volumes: - - name: certs - secret: - secretName: tunnel-certificates - - name: creds - secret: - secretName: tunnel-credentials - - name: config - configMap: - name: cloudflared - items: - - key: config.yaml - path: config.yaml ---- -apiVersion: v1 -kind: ConfigMap -metadata: - name: cloudflared -data: - config.yaml: | - tunnel: homelab - credentials-file: /etc/cloudflared/creds/credentials.json - metrics: 0.0.0.0:2000 - no-autoupdate: true - ingress: - - hostname: git.khuedoan.com - service: http://192.168.1.150 - - hostname: drone.khuedoan.com - service: http://192.168.1.150 - - service: http_status:404 diff --git a/apps/resources/vault.yaml b/apps/resources/vault.yaml deleted file mode 100644 index e879b146..00000000 --- a/apps/resources/vault.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: vault - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: vault - server: '' - source: - path: '' - repoURL: 'https://helm.releases.hashicorp.com' - targetRevision: 0.11.0 - chart: vault - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true diff --git a/apps/resources/wireguard.yaml b/apps/resources/wireguard.yaml deleted file mode 100644 index 6c763305..00000000 --- a/apps/resources/wireguard.yaml +++ /dev/null @@ -1,32 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: wireguard - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - destination: - name: in-cluster - namespace: wireguard - server: '' - source: - path: '' - repoURL: 'https://place1.github.io/wg-access-server' - targetRevision: v0.4.6 - chart: wg-access-server - helm: - parameters: - - name: 'web.config.adminUsername' - value: 'admin' - - name: 'web.config.adminPassword' - value: 'admin' - # - name: 'ingress.hosts' - # value: - # - "vpn.khuedoan.com" - project: default - syncPolicy: - automated: - prune: true - selfHeal: true - syncOptions: - - CreateNamespace=true