From 0ffcd5414e56fbf5b64679db67d2836286161e7b Mon Sep 17 00:00:00 2001 From: SeanOMik Date: Sat, 8 Apr 2023 14:54:22 -0400 Subject: [PATCH] Change 'vpn-pods' to 'qbittorrent' and move it inside the download ns --- .../{vpn => qbittorrent}/deployment.yaml | 12 ++++----- .../{vpn => qbittorrent}/ingress.yaml | 6 ++--- .../{vpn => qbittorrent}/kustomization.yaml | 0 .../qbittorrent.sops.yaml} | 8 +++--- .../apps/download/qbittorrent/service.yaml | 16 ++++++++++++ cluster/apps/download/vpn/namespace.yaml | 6 ----- cluster/apps/download/vpn/network_policy.yaml | 25 ------------------- cluster/apps/download/vpn/service.yaml | 16 ------------ 8 files changed, 29 insertions(+), 60 deletions(-) rename cluster/apps/download/{vpn => qbittorrent}/deployment.yaml (86%) rename cluster/apps/download/{vpn => qbittorrent}/ingress.yaml (80%) rename cluster/apps/download/{vpn => qbittorrent}/kustomization.yaml (100%) rename cluster/apps/download/{vpn/vpnconfig.sops.yaml => qbittorrent/qbittorrent.sops.yaml} (90%) create mode 100644 cluster/apps/download/qbittorrent/service.yaml delete mode 100644 cluster/apps/download/vpn/namespace.yaml delete mode 100644 cluster/apps/download/vpn/network_policy.yaml delete mode 100644 cluster/apps/download/vpn/service.yaml diff --git a/cluster/apps/download/vpn/deployment.yaml b/cluster/apps/download/qbittorrent/deployment.yaml similarity index 86% rename from cluster/apps/download/vpn/deployment.yaml rename to cluster/apps/download/qbittorrent/deployment.yaml index 54c6144..96b736e 100644 --- a/cluster/apps/download/vpn/deployment.yaml +++ b/cluster/apps/download/qbittorrent/deployment.yaml @@ -1,21 +1,21 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: vpn-pods - namespace: vpn + name: qbittorrent + namespace: download labels: - app: vpn-pods - kubernetes.io/name: "vpn-pods" + app: qbittorrent + kubernetes.io/name: "qbittorrent" spec: replicas: 1 selector: matchLabels: - app: vpn-pods + app: qbittorrent template: metadata: labels: - app: vpn-pods + app: qbittorrent spec: containers: - name: qbittorrent diff --git a/cluster/apps/download/vpn/ingress.yaml b/cluster/apps/download/qbittorrent/ingress.yaml similarity index 80% rename from cluster/apps/download/vpn/ingress.yaml rename to cluster/apps/download/qbittorrent/ingress.yaml index 244c48b..b11e531 100644 --- a/cluster/apps/download/vpn/ingress.yaml +++ b/cluster/apps/download/qbittorrent/ingress.yaml @@ -1,8 +1,8 @@ apiVersion: networking.k8s.io/v1 kind: Ingress metadata: - name: vpn-pods-ingress - namespace: vpn + name: qbittorrent-ingress + namespace: download annotations: cert-manager.io/cluster-issuer: "letsencrypt-production" traefik.ingress.kubernetes.io/router.entrypoints: websecure @@ -16,6 +16,6 @@ spec: pathType: Prefix backend: service: - name: vpn-pods + name: qbittorrent port: name: http \ No newline at end of file diff --git a/cluster/apps/download/vpn/kustomization.yaml b/cluster/apps/download/qbittorrent/kustomization.yaml similarity index 100% rename from cluster/apps/download/vpn/kustomization.yaml rename to cluster/apps/download/qbittorrent/kustomization.yaml diff --git a/cluster/apps/download/vpn/vpnconfig.sops.yaml b/cluster/apps/download/qbittorrent/qbittorrent.sops.yaml similarity index 90% rename from cluster/apps/download/vpn/vpnconfig.sops.yaml rename to cluster/apps/download/qbittorrent/qbittorrent.sops.yaml index 05a396d..dfbc819 100644 --- a/cluster/apps/download/vpn/vpnconfig.sops.yaml +++ b/cluster/apps/download/qbittorrent/qbittorrent.sops.yaml @@ -1,8 +1,8 @@ apiVersion: v1 kind: Secret metadata: - name: vpnconfig - namespace: vpn + name: qbittorrent + namespace: download stringData: VPN_SERVICE_PROVIDER: ENC[AES256_GCM,data:R8/w2f+rPQ==,iv:jy1iVRtJq9l/fYKjCdSrSneNZh8V9/LHVopGWdjtpNY=,tag:HkzAyAuflvqEcdHGF6jnfw==,type:str] VPN_TYPE: ENC[AES256_GCM,data:Dff2qD9mAVX7,iv:jhLEkfAulvPxN/uRdSF3MR9GbxnRt2cSLqDOkXO7qPA=,tag:dMB6aEhwLssc3JPKdFULTQ==,type:str] @@ -16,8 +16,8 @@ sops: azure_kv: [] hc_vault: [] age: [] - lastmodified: "2023-04-06T15:52:45Z" - mac: ENC[AES256_GCM,data:tXyfA8DwqQCjcG+Iah7BiO5y/jGAqiuqOBKebJHABKEjr44HnEKT+LnZFRPRVlIuZZ545ZeyU2Bzhpr6WBz6NVjk2b+ab+bHDYYOGMOwLAvXtLsNqhDXsRtqj9jfr5tubfRmAcMcdgCZE+qOlJt/yjRevzvUgs+cAtrO4xAcldU=,iv:YRNS67GjORbBBj8Fyps3PWzugzsDP1kFrR6/TiCSYe0=,tag:h3kFZuuKygDKWMp1htW66A==,type:str] + lastmodified: "2023-04-08T18:52:53Z" + mac: ENC[AES256_GCM,data:s8/Cii5c9LXJLN6WtBswLwd6UEJtxa48jVYyKFN014CAiP+hCyv0q17JMjXjrrQdpNZt3nXuhZRsIJiPg4p7jcz9wqdfLws5DFj5Je5ZuYD7KYWABMoiUnNHB6E7x/WU5A0JkFYDJbyALzifv8rNNAl8A14zkT3hfKEl/Lf4Z4g=,iv:A+aLnHYBvh2AO2crSNap1HtCjrInqAjbMhZvJ4ww6BQ=,tag:vysZl5tg3noWA+8DvEFRoQ==,type:str] pgp: - created_at: "2023-04-06T03:41:51Z" enc: | diff --git a/cluster/apps/download/qbittorrent/service.yaml b/cluster/apps/download/qbittorrent/service.yaml new file mode 100644 index 0000000..95ac16e --- /dev/null +++ b/cluster/apps/download/qbittorrent/service.yaml @@ -0,0 +1,16 @@ +apiVersion: v1 +kind: Service +metadata: + name: qbittorrent + namespace: download + + labels: + app: qbittorrent + kubernetes.io/name: "qbittorrent" +spec: + selector: + app: qbittorrent + ports: + - name: http + port: 8080 + targetPort: 8080 \ No newline at end of file diff --git a/cluster/apps/download/vpn/namespace.yaml b/cluster/apps/download/vpn/namespace.yaml deleted file mode 100644 index fb11e17..0000000 --- a/cluster/apps/download/vpn/namespace.yaml +++ /dev/null @@ -1,6 +0,0 @@ -apiVersion: v1 -kind: Namespace -metadata: - name: vpn - labels: - name: vpn \ No newline at end of file diff --git a/cluster/apps/download/vpn/network_policy.yaml b/cluster/apps/download/vpn/network_policy.yaml deleted file mode 100644 index 2f746cc..0000000 --- a/cluster/apps/download/vpn/network_policy.yaml +++ /dev/null @@ -1,25 +0,0 @@ -apiVersion: networking.k8s.io/v1 -kind: NetworkPolicy -metadata: - name: deny-most-allow-some - namespace: vpn -spec: - # Apply to all pods in this namespace - podSelector: {} - ingress: - - from: - # Allow all pods in this namespace - - namespaceSelector: - matchLabels: - name: "vpn" -# - podSelector: {} - - # Allow traefik pods - - namespaceSelector: - matchLabels: - name: "traefik" - - # Allow all pods with this label - - podSelector: - matchLabels: - needsVPN: "yes" \ No newline at end of file diff --git a/cluster/apps/download/vpn/service.yaml b/cluster/apps/download/vpn/service.yaml deleted file mode 100644 index 23cbab1..0000000 --- a/cluster/apps/download/vpn/service.yaml +++ /dev/null @@ -1,16 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: vpn-pods - namespace: vpn - - labels: - app: vpn-pods - kubernetes.io/name: "vpn-pods" -spec: - selector: - app: vpn-pods - ports: - - name: http - port: 8080 - targetPort: 8080 \ No newline at end of file