From 0fbdebf6681193a2aa7a22700b48bf2fe8304727 Mon Sep 17 00:00:00 2001 From: StevenMcElligott <89483932+StevenMcElligott@users.noreply.github.com> Date: Wed, 6 Dec 2023 00:07:09 -0500 Subject: [PATCH] migrate(awesome-ttrss): Migrate to new common (#15787) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit **Description** Another simple chart (done by Sagit back in the day) that can be migrated ⚒️ Fixes # **⚙️ Type of change** - [ ] ⚙️ Feature/App addition - [ ] 🪛 Bugfix - [ ] ⚠️ Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] 🔃 Refactor of current code **🧪 How Has This Been Tested?** **📃 Notes:** **✔️ Checklist:** - [ ] ⚖️ My code follows the style guidelines of this project - [ ] 👀 I have performed a self-review of my own code - [ ] #️⃣ I have commented my code, particularly in hard-to-understand areas - [ ] 📄 I have made corresponding changes to the documentation - [ ] ⚠️ My changes generate no new warnings - [ ] 🧪 I have added tests to this description that prove my fix is effective or that my feature works - [ ] ⬆️ I increased versions for any altered app according to semantic versioning **➕ App addition** If this PR is an app addition please make sure you have done the following. - [ ] 🪞 I have opened a PR on [truecharts/containers](https://github.com/truecharts/containers) adding the container to TrueCharts mirror repo. - [ ] 🖼️ I have added an icon in the Chart's root directory called `icon.png` --- _Please don't blindly check all the boxes. Read them and only check those that apply. Those checkboxes are there for the reviewer to see what is this all about and the status of this PR with a quick glance._ --- charts/incubator/awesome-ttrss/Chart.yaml | 13 +--- charts/incubator/awesome-ttrss/questions.yaml | 8 +-- .../awesome-ttrss/templates/common.yaml | 2 +- charts/incubator/awesome-ttrss/values.yaml | 72 ++++++++++--------- 4 files changed, 43 insertions(+), 52 deletions(-) diff --git a/charts/incubator/awesome-ttrss/Chart.yaml b/charts/incubator/awesome-ttrss/Chart.yaml index 44f0fda99ef..5c908feef06 100644 --- a/charts/incubator/awesome-ttrss/Chart.yaml +++ b/charts/incubator/awesome-ttrss/Chart.yaml @@ -1,8 +1,8 @@ kubeVersion: ">=1.24.0" apiVersion: v2 name: awesome-ttrss -version: 3.0.25 -appVersion: 2022-04 +version: 4.0.0 +appVersion: latest description: Awesome TTRSS aims to provide a powerful Chartized all-in-one solution for Tiny Tiny RSS @@ -22,19 +22,12 @@ keywords: - awesome-ttrss dependencies: - name: common - version: 11.1.2 + version: 15.3.3 repository: https://library-charts.truecharts.org condition: "" alias: "" tags: [] import-values: [] - - name: postgresql - version: 11.0.31 - repository: https://deps.truecharts.org/ - condition: postgresql.enabled - alias: "" - tags: [] - import-values: [] annotations: max_scale_version: 23.10.1 min_scale_version: 22.12.4 diff --git a/charts/incubator/awesome-ttrss/questions.yaml b/charts/incubator/awesome-ttrss/questions.yaml index 092c9e42700..d77a3a7185f 100644 --- a/charts/incubator/awesome-ttrss/questions.yaml +++ b/charts/incubator/awesome-ttrss/questions.yaml @@ -28,13 +28,7 @@ questions: # Include{containerConfig} # Include{podOptions} # Include{serviceRoot} - - variable: main - label: "Main Service" - description: "The Primary service on which the healthcheck runs, often the webUI" - schema: - additional_attrs: true - type: dict - attrs: +# Include{serviceSelectorMain} # Include{serviceSelectorLoadBalancer} # Include{serviceSelectorExtras} - variable: main diff --git a/charts/incubator/awesome-ttrss/templates/common.yaml b/charts/incubator/awesome-ttrss/templates/common.yaml index 45d48a1f3ae..72bdd2d48fe 100644 --- a/charts/incubator/awesome-ttrss/templates/common.yaml +++ b/charts/incubator/awesome-ttrss/templates/common.yaml @@ -1,2 +1,2 @@ {{/* Make sure all variables are set properly */}} -{{- include "tc.common.loader.all" . }} +{{- include "tc.v1.common.loader.all" . }} diff --git a/charts/incubator/awesome-ttrss/values.yaml b/charts/incubator/awesome-ttrss/values.yaml index 279b45eff76..8e18e47d27e 100644 --- a/charts/incubator/awesome-ttrss/values.yaml +++ b/charts/incubator/awesome-ttrss/values.yaml @@ -1,15 +1,40 @@ image: - repository: tccr.io/truecharts/awesome-ttrss + repository: wangqiru/ttrss pullPolicy: IfNotPresent - tag: v2022-04@sha256:9c7257b4c850698b320e306f28d97c1aed7f6831bec4a1fc9f7698e698e65da8 + tag: latest@sha256:b883ac1dad416ecf17cb351f641497348912e9790c3600f36bdd4436c5872b14 securityContext: - readOnlyRootFilesystem: false - runAsNonRoot: false + container: + readOnlyRootFilesystem: false + runAsNonRoot: false + runAsUser: 0 + runAsGroup: 0 -podSecurityContext: - runAsUser: 0 - runAsGroup: 0 +workload: + main: + podSpec: + containers: + main: + env: + SELF_URL_PATH: "" + DB_NAME: "{{ .Values.cnpg.main.database }}" + DB_USER: "{{ .Values.cnpg.main.user }}" + DB_PORT: "5432" + DB_PASS: + secretKeyRef: + name: cnpg-main-user + key: password + DB_HOST: + secretKeyRef: + name: cnpg-main-urls + key: host + +service: + main: + ports: + main: + port: 10246 + targetPort: 80 persistence: icons: @@ -22,33 +47,12 @@ persistence: enabled: true mountPath: "/var/www/themes.local" -env: - # -- External URL you use to connect to the RSS (the one you enter in your browser) - SELF_URL_PATH: "" - DB_NAME: "{{ .Values.postgresql.postgresqlDatabase }}" - DB_USER: "{{ .Values.postgresql.postgresqlUsername }}" - DB_PORT: "5432" - DB_PASS: - secretKeyRef: - name: dbcreds - key: postgresql-password - DB_HOST: - secretKeyRef: - name: dbcreds - key: plainhost - -service: +cnpg: main: - ports: - main: - port: 10246 - targetPort: 80 - -postgresql: - enabled: true - existingSecret: "dbcreds" - postgresqlUsername: awesome-ttrss - postgresqlDatabase: awesome-ttrss + enabled: true + user: awesome-ttrss + database: awesome-ttrss portal: - enabled: true + open: + enabled: true