Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(kube-web-view): migrate to app-template #541

Merged
merged 1 commit into from
Mar 25, 2024

Conversation

martinohmann
Copy link
Owner

@martinohmann martinohmann commented Mar 25, 2024

Aligns it closer with all the other apps. Also avoids running into sporadic git errors when codeberg has small hiccups.

Aligns it closes with all the other apps. Also avoids running into
sporadic git errors when codeberg has small hiccups.
@github-actions github-actions bot added the area/kubernetes Changes made in the kubernetes directory label Mar 25, 2024
Copy link

--- HelmRelease: monitoring/kube-web-view Service: monitoring/kube-web-view

+++ HelmRelease: monitoring/kube-web-view Service: monitoring/kube-web-view

@@ -0,0 +1,22 @@

+---
+apiVersion: v1
+kind: Service
+metadata:
+  name: kube-web-view
+  labels:
+    app.kubernetes.io/instance: kube-web-view
+    app.kubernetes.io/managed-by: Helm
+    app.kubernetes.io/name: kube-web-view
+    app.kubernetes.io/service: kube-web-view
+spec:
+  type: ClusterIP
+  ports:
+  - port: 8080
+    targetPort: 8080
+    protocol: TCP
+    name: http
+  selector:
+    app.kubernetes.io/component: kube-web-view
+    app.kubernetes.io/instance: kube-web-view
+    app.kubernetes.io/name: kube-web-view
+
--- HelmRelease: monitoring/kube-web-view Deployment: monitoring/kube-web-view

+++ HelmRelease: monitoring/kube-web-view Deployment: monitoring/kube-web-view

@@ -0,0 +1,51 @@

+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+  name: kube-web-view
+  labels:
+    app.kubernetes.io/component: kube-web-view
+    app.kubernetes.io/instance: kube-web-view
+    app.kubernetes.io/managed-by: Helm
+    app.kubernetes.io/name: kube-web-view
+spec:
+  revisionHistoryLimit: 3
+  replicas: 1
+  strategy:
+    type: RollingUpdate
+  selector:
+    matchLabels:
+      app.kubernetes.io/component: kube-web-view
+      app.kubernetes.io/name: kube-web-view
+      app.kubernetes.io/instance: kube-web-view
+  template:
+    metadata:
+      labels:
+        app.kubernetes.io/component: kube-web-view
+        app.kubernetes.io/instance: kube-web-view
+        app.kubernetes.io/name: kube-web-view
+    spec:
+      enableServiceLinks: false
+      serviceAccountName: kube-web-view
+      automountServiceAccountToken: true
+      hostIPC: false
+      hostNetwork: false
+      hostPID: false
+      dnsPolicy: ClusterFirst
+      containers:
+      - args:
+        - --port=8080
+        - --show-container-logs
+        image: hjacobs/kube-web-view:23.8.0
+        name: app
+        readinessProbe:
+          httpGet:
+            path: /health
+            port: 8080
+        resources:
+          limits:
+            memory: 100Mi
+          requests:
+            cpu: 5m
+            memory: 100Mi
+
--- HelmRelease: monitoring/kube-web-view Ingress: monitoring/kube-web-view

+++ HelmRelease: monitoring/kube-web-view Ingress: monitoring/kube-web-view

@@ -0,0 +1,31 @@

+---
+apiVersion: networking.k8s.io/v1
+kind: Ingress
+metadata:
+  name: kube-web-view
+  labels:
+    app.kubernetes.io/instance: kube-web-view
+    app.kubernetes.io/managed-by: Helm
+    app.kubernetes.io/name: kube-web-view
+  annotations:
+    gethomepage.dev/enabled: 'true'
+    gethomepage.dev/group: Observability
+    gethomepage.dev/icon: kubernetes.png
+    gethomepage.dev/name: Kube Web View
+spec:
+  ingressClassName: internal
+  tls:
+  - hosts:
+    - kube-web-view.18b.haus
+  rules:
+  - host: kube-web-view.18b.haus
+    http:
+      paths:
+      - path: /
+        pathType: Prefix
+        backend:
+          service:
+            name: kube-web-view
+            port:
+              number: 8080
+

Copy link

--- kubernetes/apps/flux-system/addons/notifications Kustomization: flux-system/flux-notifications Alert: flux-system/alertmanager

+++ kubernetes/apps/flux-system/addons/notifications Kustomization: flux-system/flux-notifications Alert: flux-system/alertmanager

@@ -61,11 +61,10 @@

   exclusionList:
   - error.*lookup github\.com
   - error.*lookup raw\.githubusercontent\.com
   - dial.*tcp.*timeout
   - waiting.*socket
   - 'requested URL returned error: 50[023]'
-  - timeout.*codeberg\.org
   providerRef:
     name: alertmanager
   suspend: false
 
--- kubernetes/apps/monitoring/kube-web-view/app Kustomization: flux-system/kube-web-view Ingress: monitoring/kube-web-view

+++ kubernetes/apps/monitoring/kube-web-view/app Kustomization: flux-system/kube-web-view Ingress: monitoring/kube-web-view

@@ -1,33 +0,0 @@

----
-apiVersion: networking.k8s.io/v1
-kind: Ingress
-metadata:
-  annotations:
-    gethomepage.dev/enabled: 'true'
-    gethomepage.dev/group: Observability
-    gethomepage.dev/icon: kubernetes.png
-    gethomepage.dev/name: Kube Web View
-    gethomepage.dev/pod-selector: application=kube-web-view
-  labels:
-    app.kubernetes.io/name: kube-web-view
-    kustomize.toolkit.fluxcd.io/name: kube-web-view
-    kustomize.toolkit.fluxcd.io/namespace: flux-system
-  name: kube-web-view
-  namespace: monitoring
-spec:
-  ingressClassName: internal
-  rules:
-  - host: kube-web-view.18b.haus
-    http:
-      paths:
-      - backend:
-          service:
-            name: kube-web-view
-            port:
-              number: 80
-        path: /
-        pathType: Prefix
-  tls:
-  - hosts:
-    - kube-web-view.18b.haus
-
--- kubernetes/apps/monitoring/kube-web-view/app Kustomization: flux-system/kube-web-view Deployment: monitoring/kube-web-view

+++ kubernetes/apps/monitoring/kube-web-view/app Kustomization: flux-system/kube-web-view Deployment: monitoring/kube-web-view

@@ -1,46 +0,0 @@

----
-apiVersion: apps/v1
-kind: Deployment
-metadata:
-  labels:
-    app.kubernetes.io/name: kube-web-view
-    application: kube-web-view
-    kustomize.toolkit.fluxcd.io/name: kube-web-view
-    kustomize.toolkit.fluxcd.io/namespace: flux-system
-  name: kube-web-view
-  namespace: monitoring
-spec:
-  replicas: 1
-  revisionHistoryLimit: 3
-  selector:
-    matchLabels:
-      application: kube-web-view
-  template:
-    metadata:
-      labels:
-        application: kube-web-view
-    spec:
-      containers:
-      - args:
-        - --port=8080
-        - --show-container-logs
-        image: hjacobs/kube-web-view:23.8.0
-        name: kube-web-view
-        ports:
-        - containerPort: 8080
-        readinessProbe:
-          httpGet:
-            path: /health
-            port: 8080
-        resources:
-          limits:
-            memory: 100Mi
-          requests:
-            cpu: 5m
-            memory: 100Mi
-        securityContext:
-          readOnlyRootFilesystem: true
-          runAsNonRoot: true
-          runAsUser: 1000
-      serviceAccountName: kube-web-view
-
--- kubernetes/apps/monitoring/kube-web-view/app Kustomization: flux-system/kube-web-view Service: monitoring/kube-web-view

+++ kubernetes/apps/monitoring/kube-web-view/app Kustomization: flux-system/kube-web-view Service: monitoring/kube-web-view

@@ -1,20 +0,0 @@

----
-apiVersion: v1
-kind: Service
-metadata:
-  labels:
-    app.kubernetes.io/name: kube-web-view
-    application: kube-web-view
-    kustomize.toolkit.fluxcd.io/name: kube-web-view
-    kustomize.toolkit.fluxcd.io/namespace: flux-system
-  name: kube-web-view
-  namespace: monitoring
-spec:
-  ports:
-  - port: 80
-    protocol: TCP
-    targetPort: 8080
-  selector:
-    application: kube-web-view
-  type: ClusterIP
-
--- kubernetes/apps/monitoring/kube-web-view/app Kustomization: flux-system/kube-web-view HelmRelease: monitoring/kube-web-view

+++ kubernetes/apps/monitoring/kube-web-view/app Kustomization: flux-system/kube-web-view HelmRelease: monitoring/kube-web-view

@@ -0,0 +1,89 @@

+---
+apiVersion: helm.toolkit.fluxcd.io/v2beta2
+kind: HelmRelease
+metadata:
+  labels:
+    app.kubernetes.io/name: kube-web-view
+    kustomize.toolkit.fluxcd.io/name: kube-web-view
+    kustomize.toolkit.fluxcd.io/namespace: flux-system
+  name: kube-web-view
+  namespace: monitoring
+spec:
+  chart:
+    spec:
+      chart: app-template
+      sourceRef:
+        kind: HelmRepository
+        name: bjw-s
+        namespace: flux-system
+      version: 3.0.4
+  install:
+    remediation:
+      retries: 3
+  interval: 2h
+  uninstall:
+    keepHistory: false
+  upgrade:
+    cleanupOnFail: true
+    remediation:
+      retries: 3
+      strategy: uninstall
+  values:
+    controllers:
+      kube-web-view:
+        containers:
+          app:
+            args:
+            - --port=8080
+            - --show-container-logs
+            image:
+              repository: hjacobs/kube-web-view
+              tag: 23.8.0
+            probes:
+              readiness:
+                custom: true
+                enabled: true
+                spec:
+                  httpGet:
+                    path: /health
+                    port: 8080
+            resources:
+              limits:
+                memory: 100Mi
+              requests:
+                cpu: 5m
+                memory: 100Mi
+        strategy: RollingUpdate
+    ingress:
+      app:
+        annotations:
+          gethomepage.dev/enabled: 'true'
+          gethomepage.dev/group: Observability
+          gethomepage.dev/icon: kubernetes.png
+          gethomepage.dev/name: Kube Web View
+        className: internal
+        enabled: true
+        hosts:
+        - host: kube-web-view.18b.haus
+          paths:
+          - path: /
+            service:
+              identifier: app
+              port: http
+        tls:
+        - hosts:
+          - kube-web-view.18b.haus
+    pod:
+      securityContext:
+        readOnlyRootFilesystem: true
+        runAsNonRoot: true
+        runAsUser: 1000
+    service:
+      app:
+        controller: kube-web-view
+        ports:
+          http:
+            port: 8080
+    serviceAccount:
+      name: kube-web-view
+

@martinohmann martinohmann merged commit 35e8c8f into main Mar 25, 2024
4 checks passed
@martinohmann martinohmann deleted the kube-web-view/app-template branch March 25, 2024 14:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/kubernetes Changes made in the kubernetes directory
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant