From a8b31c4c23cfc811d7703b5fa292c9c869cdeaf4 Mon Sep 17 00:00:00 2001 From: Aaron Riedel Date: Thu, 10 Oct 2024 21:31:56 +0200 Subject: [PATCH] remove pipeline --- .drone.yml | 88 ------------------------------------ app-files/apps.yaml | 6 +-- hoylogo/prod/.gitkeep | 0 hoylogo/prod/hoylogo.yaml | 71 ----------------------------- hoylogo/staging/.gitkeep | 0 hoylogo/staging/hoylogo.yaml | 71 ----------------------------- 6 files changed, 3 insertions(+), 233 deletions(-) delete mode 100644 .drone.yml delete mode 100644 hoylogo/prod/.gitkeep delete mode 100644 hoylogo/prod/hoylogo.yaml delete mode 100644 hoylogo/staging/.gitkeep delete mode 100644 hoylogo/staging/hoylogo.yaml diff --git a/.drone.yml b/.drone.yml deleted file mode 100644 index 6cdbde0..0000000 --- a/.drone.yml +++ /dev/null @@ -1,88 +0,0 @@ -kind: pipeline -name: deploy -steps: -- name: kustomize build hoylogo (prod + staging) - image: git.ar21.de/aaron/kustomize-ci - commands: - - cd /deployment-repo - - git clone https://git.ar21.de/aaron/k8s-deployments.git . - - cd /deployment-repo/hoylogo/overlays/prod - - kustomize build -o /deployment-repo/hoylogo/prod/hoylogo.yaml - - cd /deployment-repo/hoylogo/overlays/staging - - kustomize build -o /deployment-repo/hoylogo/staging/hoylogo.yaml - volumes: - - name: deployment-repo - path: /deployment-repo - when: - branch: - - main - event: - - push -- name: kustomize build hoylogo (staging) - image: git.ar21.de/aaron/kustomize-ci - commands: - - cd /deployment-repo - - git clone https://git.ar21.de/aaron/k8s-deployments.git . - - cd /staging-repo - - git clone -b $DRONE_BRANCH https://git.ar21.de/aaron/k8s-deployments.git . - - cd /staging-repo/hoylogo/overlays/staging - - kustomize build -o /deployment-repo/hoylogo/staging/hoylogo.yaml - volumes: - - name: deployment-repo - path: /deployment-repo - - name: staging-repo - path: /staging-repo - when: - branch: - exclude: - - main - event: - - push -- name: kustomize push hoylogo changes (prod + staging) - image: appleboy/drone-git-push - settings: - branch: main - remote: ssh://git@git.ar21.de:2222/aaron/k8s-deployments.git - path: /deployment-repo - force: false - commit: true - commit_message: "KUSTOMIZE BUILD: rebuild hoylogo deployment with kustomize ${DRONE_BUILD_NUMBER} (done automagically via Drone pipeline) [CI SKIP]" - ssh_key: - from_secret: GITEA_SSH_KEY - volumes: - - name: deployment-repo - path: /deployment-repo - when: - branch: - - main - event: - - push -- name: kustomize push hoylogo changes (staging) - image: appleboy/drone-git-push - settings: - branch: main - remote: ssh://git@git.ar21.de:2222/aaron/k8s-deployments.git - path: /deployment-repo - force: false - commit: true - commit_message: "KUSTOMIZE BUILD STAGING: rebuild hoylogo deployment with kustomize ${DRONE_BUILD_NUMBER} [CI SKIP]" - ssh_key: - from_secret: GITEA_SSH_KEY - volumes: - - name: deployment-repo - path: /deployment-repo - when: - branch: - exclude: - - main - event: - - push -volumes: -- name: deployment-repo - temp: {} -- name: staging-repo - temp: {} -when: - event: - exclude: - - pull_request \ No newline at end of file diff --git a/app-files/apps.yaml b/app-files/apps.yaml index 632d0f4..41bc31c 100644 --- a/app-files/apps.yaml +++ b/app-files/apps.yaml @@ -79,7 +79,7 @@ spec: source: repoURL: https://git.ar21.de/aaron/k8s-deployments.git targetRevision: HEAD - path: hoylogo/prod + path: hoylogo/overlays/prod destination: server: https://kubernetes.default.svc namespace: hoylogo @@ -99,7 +99,7 @@ spec: source: repoURL: https://git.ar21.de/aaron/k8s-deployments.git targetRevision: HEAD - path: hoylogo/staging + path: hoylogo/overlays/staging destination: server: https://kubernetes.default.svc namespace: hoylogo-staging @@ -127,4 +127,4 @@ spec: syncOptions: - CreateNamespace=true automated: - prune: true \ No newline at end of file + prune: true diff --git a/hoylogo/prod/.gitkeep b/hoylogo/prod/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/hoylogo/prod/hoylogo.yaml b/hoylogo/prod/hoylogo.yaml deleted file mode 100644 index 148046f..0000000 --- a/hoylogo/prod/hoylogo.yaml +++ /dev/null @@ -1,71 +0,0 @@ -apiVersion: v1 -kind: Namespace -metadata: - name: hoylogo ---- -apiVersion: v1 -kind: Service -metadata: - name: hoylogo-service - namespace: hoylogo -spec: - ports: - - port: 80 - protocol: TCP - targetPort: 80 - selector: - app: hoylogo ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - app: hoylogo - name: hoylogo-deployment - namespace: hoylogo -spec: - replicas: 3 - selector: - matchLabels: - app: hoylogo - template: - metadata: - labels: - app: hoylogo - spec: - containers: - - image: git.ar21.de/aaron/hoylogo:27 - imagePullPolicy: Always - livenessProbe: - httpGet: - path: / - port: 80 - initialDelaySeconds: 4 - periodSeconds: 3 - name: hoylogo - ports: - - containerPort: 80 ---- -apiVersion: networking.k8s.io/v1 -kind: Ingress -metadata: - annotations: - kubernetes.io/tls-acme: "true" - name: hoylogo-ingress - namespace: hoylogo -spec: - rules: - - host: hoylogo-prod.apps.yolokube.de - http: - paths: - - backend: - service: - name: hoylogo-service - port: - number: 80 - path: / - pathType: Prefix - tls: - - hosts: - - hoylogo-prod.apps.yolokube.de - secretName: hoylogo-tls-key diff --git a/hoylogo/staging/.gitkeep b/hoylogo/staging/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/hoylogo/staging/hoylogo.yaml b/hoylogo/staging/hoylogo.yaml deleted file mode 100644 index e2ad9a2..0000000 --- a/hoylogo/staging/hoylogo.yaml +++ /dev/null @@ -1,71 +0,0 @@ -apiVersion: v1 -kind: Namespace -metadata: - name: hoylogo-staging ---- -apiVersion: v1 -kind: Service -metadata: - name: hoylogo-service - namespace: hoylogo-staging -spec: - ports: - - port: 80 - protocol: TCP - targetPort: 80 - selector: - app: hoylogo ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - app: hoylogo - name: hoylogo-deployment - namespace: hoylogo-staging -spec: - replicas: 1 - selector: - matchLabels: - app: hoylogo - template: - metadata: - labels: - app: hoylogo - spec: - containers: - - image: git.ar21.de/aaron/hoylogo:staging-28 - imagePullPolicy: Always - livenessProbe: - httpGet: - path: / - port: 80 - initialDelaySeconds: 4 - periodSeconds: 3 - name: hoylogo - ports: - - containerPort: 80 ---- -apiVersion: networking.k8s.io/v1 -kind: Ingress -metadata: - annotations: - kubernetes.io/tls-acme: "true" - name: hoylogo-ingress - namespace: hoylogo-staging -spec: - rules: - - host: staging.hoylogo.de - http: - paths: - - backend: - service: - name: hoylogo-service - port: - number: 80 - path: / - pathType: Prefix - tls: - - hosts: - - staging.hoylogo.de - secretName: hoylogo-tls-key