From 44224bbb6cf6e616ebbc50e5b83154d51a5d041f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Mu=CC=88hlebach?= Date: Fri, 20 Oct 2023 10:59:18 +0200 Subject: [PATCH 1/5] feat: add rpg apps of app with dmw --- .../applications/cluster-rpg-apps.yaml | 27 ++++++++++++++++++ apps-root-config/bootstrap/values.yaml | 1 + cluster-rpg-apps/dmw/Chart.yaml | 8 ++++++ cluster-rpg-apps/dmw/values.yaml | 28 +++++++++++++++++++ 4 files changed, 64 insertions(+) create mode 100644 apps-root-config/applications/cluster-rpg-apps.yaml create mode 100644 cluster-rpg-apps/dmw/Chart.yaml create mode 100644 cluster-rpg-apps/dmw/values.yaml diff --git a/apps-root-config/applications/cluster-rpg-apps.yaml b/apps-root-config/applications/cluster-rpg-apps.yaml new file mode 100644 index 000000000..b53d0b3f3 --- /dev/null +++ b/apps-root-config/applications/cluster-rpg-apps.yaml @@ -0,0 +1,27 @@ +repository: https://github.com/mikevader/k3s-cluster-infra-apps.git +#argocdNamespace: "argocd" +#server: "https://kubernetes.default.svc" +subFolder: cluster-rpg-apps +namespace: + annotations: {} + labels: + client: cluster-infra + +enableDefaultNetworkPolicy: false +enableDefaultLimitRange: false +allowAllNamespaces: true + +roleBindings: +# - groupName: "team1" +# clusterRoleName: "admin" + +clusterResourceWhitelist: +- group: '*' + kind: '*' + +namespaceResourceBlacklist: +# - group: 'apps' +# kind: 'DaemonSet' + +applications: + dmw: {} diff --git a/apps-root-config/bootstrap/values.yaml b/apps-root-config/bootstrap/values.yaml index da3f155a4..407757a2d 100644 --- a/apps-root-config/bootstrap/values.yaml +++ b/apps-root-config/bootstrap/values.yaml @@ -6,4 +6,5 @@ bootstrap: - name: cluster-platform-apps - name: cluster-utility-apps - name: cluster-media-apps + - name: cluster-rpg-apps - name: cluster-test diff --git a/cluster-rpg-apps/dmw/Chart.yaml b/cluster-rpg-apps/dmw/Chart.yaml new file mode 100644 index 000000000..d5d48f41d --- /dev/null +++ b/cluster-rpg-apps/dmw/Chart.yaml @@ -0,0 +1,8 @@ +apiVersion: v2 +name: dmw +description: Dungeon Master Workshop app +version: 1.0.0 +dependencies: + - name: dmw + repository: https://mikevader.github.io/dm-workshop + version: 1.0.0-dev.4c36ba3 diff --git a/cluster-rpg-apps/dmw/values.yaml b/cluster-rpg-apps/dmw/values.yaml new file mode 100644 index 000000000..ee0c88d75 --- /dev/null +++ b/cluster-rpg-apps/dmw/values.yaml @@ -0,0 +1,28 @@ +dmw: + railsEnvironment: development + + ingress: + enabled: true + annotations: + cert-manager.io/cluster-issuer: letsencrypt-prod + traefik.ingress.kubernetes.io/router.entrypoints: websecure + # traefik.ingress.kubernetes.io/router.middlewares: authentik-authentik@kubernetescrd + hosts: + - host: 'dmw.framsburg.ch' + paths: + - path: / + pathType: Prefix + tls: + - hosts: ['dmw.framsburg.ch'] + secretName: 'dmw-framsburg-ch-tls' + + env: + - name: SERVER_HOST_NAME + value: 'dmw.framsburg.ch' + +# podSecurityContext: +# sysctls: +# - name: fs.inotify.max_user_instances +# value: "256" + + From 3f2c5aa0af094b6d8d3811a38645b5eaa2b80dad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Mu=CC=88hlebach?= Date: Fri, 20 Oct 2023 11:01:16 +0200 Subject: [PATCH 2/5] chore: reference correct merge target branch --- .github/workflows/lint.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index dcb682cd3..54b4dec98 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -5,7 +5,7 @@ on: # yamllint disable-line rule:truthy workflow_dispatch: pull_request: branches: - - main + - master concurrency: group: ${{ github.ref }}-${{ github.workflow }} From d0e655d87782658232dfd845935f618039d5069d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Mu=CC=88hlebach?= Date: Fri, 20 Oct 2023 11:20:59 +0200 Subject: [PATCH 3/5] fix: linter issues --- apps-root-config/applications/cluster-rpg-apps.yaml | 11 ++++++----- apps-root-config/bootstrap/values.yaml | 3 ++- cluster-rpg-apps/dmw/Chart.yaml | 1 + cluster-rpg-apps/dmw/values.yaml | 3 +-- 4 files changed, 10 insertions(+), 8 deletions(-) diff --git a/apps-root-config/applications/cluster-rpg-apps.yaml b/apps-root-config/applications/cluster-rpg-apps.yaml index b53d0b3f3..187430a39 100644 --- a/apps-root-config/applications/cluster-rpg-apps.yaml +++ b/apps-root-config/applications/cluster-rpg-apps.yaml @@ -1,6 +1,7 @@ +--- repository: https://github.com/mikevader/k3s-cluster-infra-apps.git -#argocdNamespace: "argocd" -#server: "https://kubernetes.default.svc" +# argocdNamespace: "argocd" +# server: "https://kubernetes.default.svc" subFolder: cluster-rpg-apps namespace: annotations: {} @@ -16,12 +17,12 @@ roleBindings: # clusterRoleName: "admin" clusterResourceWhitelist: -- group: '*' - kind: '*' + - group: '*' + kind: '*' namespaceResourceBlacklist: # - group: 'apps' # kind: 'DaemonSet' -applications: +applications: dmw: {} diff --git a/apps-root-config/bootstrap/values.yaml b/apps-root-config/bootstrap/values.yaml index 407757a2d..5d69472f9 100644 --- a/apps-root-config/bootstrap/values.yaml +++ b/apps-root-config/bootstrap/values.yaml @@ -1,7 +1,8 @@ +--- repository: https://github.com/mikevader/k3s-cluster-infra-apps.git bootstrap: - name: cluster-init-apps -# argocdNamespace: asdfasdf + # argocdNamespace: asdfasdf - name: cluster-critical-apps - name: cluster-platform-apps - name: cluster-utility-apps diff --git a/cluster-rpg-apps/dmw/Chart.yaml b/cluster-rpg-apps/dmw/Chart.yaml index d5d48f41d..dccc30d43 100644 --- a/cluster-rpg-apps/dmw/Chart.yaml +++ b/cluster-rpg-apps/dmw/Chart.yaml @@ -1,3 +1,4 @@ +--- apiVersion: v2 name: dmw description: Dungeon Master Workshop app diff --git a/cluster-rpg-apps/dmw/values.yaml b/cluster-rpg-apps/dmw/values.yaml index ee0c88d75..9fe0780fe 100644 --- a/cluster-rpg-apps/dmw/values.yaml +++ b/cluster-rpg-apps/dmw/values.yaml @@ -1,3 +1,4 @@ +--- dmw: railsEnvironment: development @@ -24,5 +25,3 @@ dmw: # sysctls: # - name: fs.inotify.max_user_instances # value: "256" - - From 8b9e70ce62ea2f77373fe233c29817c6b409ec9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Mu=CC=88hlebach?= Date: Fri, 20 Oct 2023 14:28:11 +0200 Subject: [PATCH 4/5] chore: fix megalinter config --- .github/workflows/lint.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index 54b4dec98..773d66c7c 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -50,8 +50,8 @@ jobs: }} COPYPASTE_JSCPD_CONFIG_FILE: .github/linter/jscpd/jscpd.json KUBERNETES_DIRECTORY: '' - KUBERNETES_KUBEVAL_ARGUMENTS: --ignore-missing-schemas - KUBERNETES_KUBEVAL_FILTER_REGEX_INCLUDE: "(kubernetes)" + KUBERNETES_KUBECONFORM_ARGUMENTS: --ignore-missing-schemas + KUBERNETES_KUBECONFORM_FILTER_REGEX_EXCLUDE: "(Chart.yaml|values.yaml)" MARKDOWN_MARKDOWNLINT_CONFIG_FILE: .github/linter/markdownlint/markdownlint.yaml YAML_YAMLLINT_CONFIG_FILE: .github/linter/yamllint/.yamllint.yaml YAML_PRETTIER_CONFIG_FILE: .github/linter/prettier/.prettierrc.yaml From ba8102e22ac6e57ad105a77b5f6517bf499cbae0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Mu=CC=88hlebach?= Date: Fri, 20 Oct 2023 14:46:57 +0200 Subject: [PATCH 5/5] chore: fix linter --- .github/linter/jscpd/jscpd.json | 4 ++-- .github/linter/yamllint/.yamllint.yaml | 1 + .github/workflows/lint.yaml | 1 - 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/linter/jscpd/jscpd.json b/.github/linter/jscpd/jscpd.json index f1dac44ab..f472beae7 100644 --- a/.github/linter/jscpd/jscpd.json +++ b/.github/linter/jscpd/jscpd.json @@ -6,6 +6,7 @@ "console" ], "ignore": [ + ".disabled/**", "**/node_modules/**", "**/.git/**", "**/.direnv/**", @@ -19,8 +20,7 @@ "**/*.yml", "**/*.md", "**/*.html", - "**/*.xml", - "kubernetes/**/scripts/pushover-notify.sh" + "**/*.xml" ] } \ No newline at end of file diff --git a/.github/linter/yamllint/.yamllint.yaml b/.github/linter/yamllint/.yamllint.yaml index bb7b058db..79e9f0a2c 100644 --- a/.github/linter/yamllint/.yamllint.yaml +++ b/.github/linter/yamllint/.yamllint.yaml @@ -1,5 +1,6 @@ --- ignore: | + .disabled/ .ansible/ .direnv/ .private/ diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index 773d66c7c..6337b3566 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -40,7 +40,6 @@ jobs: "KUBERNETES_KUBESCAPE", "MARKDOWN_MARKDOWNLINT", "REPOSITORY_GIT_DIFF", - "REPOSITORY_SECRETLINT", "YAML_PRETTIER", "YAML_YAMLLINT" ]