From 8eb3437e2a86bfdc8bcb9a8f2b602c90f3cd0ee9 Mon Sep 17 00:00:00 2001 From: Xstar97TheNoob <9399967+xstar97@users.noreply.github.com> Date: Tue, 31 Oct 2023 21:00:46 -0400 Subject: [PATCH] DNM feat(answer) add answer (#12675) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit **Description** A Q&A platform software for teams at any scales. ⚒️ Fixes # **⚙️ Type of change** - [X] ⚙️ 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:** - [X] ⚖️ My code follows the style guidelines of this project - [X] 👀 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. - [X] 🪞 I have opened a PR on [truecharts/containers](https://github.com/truecharts/containers) adding the container to TrueCharts mirror repo. - [X] 🖼️ 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._ --------- Signed-off-by: Stavros Kois <47820033+stavros-k@users.noreply.github.com> Co-authored-by: Stavros Kois <47820033+stavros-k@users.noreply.github.com> Co-authored-by: Stavros kois --- charts/incubator/answer/.helmignore | 30 +++ charts/incubator/answer/CHANGELOG.md | 1 + charts/incubator/answer/Chart.yaml | 27 +++ charts/incubator/answer/README.md | 1 + charts/incubator/answer/icon.png | Bin 0 -> 1755 bytes charts/incubator/answer/questions.yaml | 177 ++++++++++++++++++ charts/incubator/answer/templates/NOTES.txt | 1 + charts/incubator/answer/templates/common.yaml | 1 + charts/incubator/answer/values.yaml | 81 ++++++++ 9 files changed, 319 insertions(+) create mode 100644 charts/incubator/answer/.helmignore create mode 100644 charts/incubator/answer/CHANGELOG.md create mode 100644 charts/incubator/answer/Chart.yaml create mode 100644 charts/incubator/answer/README.md create mode 100644 charts/incubator/answer/icon.png create mode 100644 charts/incubator/answer/questions.yaml create mode 100644 charts/incubator/answer/templates/NOTES.txt create mode 100644 charts/incubator/answer/templates/common.yaml create mode 100644 charts/incubator/answer/values.yaml diff --git a/charts/incubator/answer/.helmignore b/charts/incubator/answer/.helmignore new file mode 100644 index 00000000000..77ca5567b26 --- /dev/null +++ b/charts/incubator/answer/.helmignore @@ -0,0 +1,30 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ +# OWNERS file for Kubernetes +OWNERS +# helm-docs templates +*.gotmpl +# docs folder +/docs +# icon +icon.png diff --git a/charts/incubator/answer/CHANGELOG.md b/charts/incubator/answer/CHANGELOG.md new file mode 100644 index 00000000000..825c32f0d03 --- /dev/null +++ b/charts/incubator/answer/CHANGELOG.md @@ -0,0 +1 @@ +# Changelog diff --git a/charts/incubator/answer/Chart.yaml b/charts/incubator/answer/Chart.yaml new file mode 100644 index 00000000000..7772f3bb933 --- /dev/null +++ b/charts/incubator/answer/Chart.yaml @@ -0,0 +1,27 @@ +apiVersion: v2 +appVersion: "1.2.0" +dependencies: + - name: common + repository: https://library-charts.truecharts.org + version: 14.2.1 +deprecated: false +description: A Q&A platform software for teams at any scales. +home: https://truecharts.org/charts/incubator/answer +icon: https://truecharts.org/img/hotlink-ok/chart-icons/answer.png +keywords: + - answer + - forum +kubeVersion: ">=1.16.0-0" +maintainers: + - email: info@truecharts.org + name: TrueCharts + url: https://truecharts.org +name: answer +sources: + - https://github.com/truecharts/charts/tree/master/charts/incubator/answer + - https://github.com/answerdev/answer +type: application +version: 0.0.1 +annotations: + truecharts.org/catagories: forum + truecharts.org/SCALE-support: "true" diff --git a/charts/incubator/answer/README.md b/charts/incubator/answer/README.md new file mode 100644 index 00000000000..7e59600739c --- /dev/null +++ b/charts/incubator/answer/README.md @@ -0,0 +1 @@ +# README diff --git a/charts/incubator/answer/icon.png b/charts/incubator/answer/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..b99fca21d4d85868e51df0084ccb85217209ea16 GIT binary patch literal 1755 zcmcK3`8ON*769;|=$Lx*#ys7$9g4OjL2MCJiV#U`wG>rqi%KP-RZBfeP0^~BhE_FH z?WMM{jM$g7v{g$Jgmmot(vmPGgzseji20mzzxUjG?l1S8`+Z<P~EQ zY+TIUdvW&?;uDkZCnZ04_$Vnk<#8%4Aa zsBfreG%y+(8I4U1P0dZstu3u>t!?dX?Hz3$o$VdWj!tGL^KEAzV7`6#_FY%kXVCrr zLpKY&|M2m{An5tj+cN|{^@{ZM_VxGm5A=_M&nz~JEi%X+92y)N9vlNh!<=Ex2xnwu zWK@L9<$n2dY;0_Ne0&Z}OiWJ9fyv3Ksj2Cy>FL?oxdoBM#l@wirDc(om6g@i)vw<~ z*4Eb6*LgfXZxitO{0))6z~<)WUm{!J`}eJX2*CFCwm=}*+1U{ag?oE@`}_N%L!LKe zmy2%t)GY^FM~IZP0u+X^aC8bJQ>ekwIj=+;^$$$XY;5id_oWEEP|>8A4*`o=V^mG& zLLd?;IE<;2D|2o{;37{v(apn>k=5r33VI(UCo=B7RtdUvU6K>#j!Dj|t__gX?qqdl zeWcaOvOAOUl>Dmr`}eC^GKC3pH%Vd-cW?G5#GU2i z&75_5h#c0vMcWWjtaMm7k9dad(tjJ<#^qbv9@@qPnINQuxN+g@qwC5of?s^v-S_;0 zrlELzsc?qr=v@>OCE32v%DWADM=S8>j1}&#`;Wzs({pMDOfe3GKcgyE~F z(yY&I&ALav&e@sFFqiODzG75k#s+%%0cqR z?8I8`_}AV<&A7UUQ{01gpZTbEPNVeUgq4Nf0B5x;FnQBQ%agM?Ot;{n8awL*xeroa zFSbS|hJ5F?<|pnx`06fxV7Y1g$`Vq+lf9SfHkv!e`bj^kNm+h=8NqN?P>im3lGagC z=zBvJ4${%T>vJ9G1N1h9q(ZXm;5#&oB$vLTtYF~VaR$dRUD8$*?2;o)p-QSp4@r5) z`C+?y|G)g`;db3j9$dMxC%mY0uExKRnfcX0!}v5wJDnh}6q`Q8($QKFr{d?u=#Jqe zRMugcc(dGrLYnLls9KlfbLwl$`t24;iyASsZ_TyRmBGDvAxa+H7Z`|1YZ_!0SIJBt zUi{Hm@C3}KAZ3gEi9}+yEONC&(+%FB<;l`(zvV364BJEe>|YV`M&{D@?iBufHzu&O zgGwtvDwgmnqqaTYGxqQdI13B?U+aHaT$S@jmMVGfJ5#%()T~qGnbI|?xNJu+-b8CF z*^EQusxLJ`Nad^<`*S#T8_CHe&E2VxW`R+jUW#E~qKBQPVINyPB&%K(ek03<^;mvm zV?LvfKzoLIqe2PKYOGkEFa8FNsLC^EnLlQaoSo1bCj7eZ2Gi%tMpJ9yJ&mK4z6nIP zXQ6#-CVXa)ze`UQpBMK%%1(MEA6v{o sZz}pGBP66wp4t^4SD%}2A-aS=C_a8_CHW2gO7u@5I15`$g_&2}-*lDC7XSbN literal 0 HcmV?d00001 diff --git a/charts/incubator/answer/questions.yaml b/charts/incubator/answer/questions.yaml new file mode 100644 index 00000000000..9a7d234aaed --- /dev/null +++ b/charts/incubator/answer/questions.yaml @@ -0,0 +1,177 @@ +# Include{groups} +portals: + open: +# Include{portalLink} +questions: +# Include{global} +# Include{workload} +# Include{workloadDeployment} + +# Include{replicas1} +# Include{podSpec} +# Include{containerMain} + + +# Include{containerBasic} +# Include{containerAdvanced} + + - variable: answer + group: App Configuration + label: Answer + schema: + additional_attrs: true + type: dict + attrs: + - variable: app + label: App Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: language + label: Language + schema: + type: string + required: true + default: "en-US" + - variable: log_level + label: Log Level + schema: + type: string + required: true + default: DEBUG" + enum: + - value: DEBUG + description: Debug + - value: INFO + description: Info + - value: WARN + description: Warn + - value: ERROR + description: Error + - variable: site + label: Site Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: name + label: Name + schema: + type: string + required: true + default: "Answer" + - variable: url + label: Url + schema: + type: string + required: true + default: "http://localhost:9080" + - variable: contact_email + label: Contact Email + schema: + type: string + required: true + default: "" + - variable: admin + label: Admin Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: name + label: Admin Name + schema: + type: string + required: true + default: "" + - variable: password + label: Admin Password + schema: + type: string + required: true + private: true + min_length: 8 + default: "" + - variable: email + label: Admin Email + schema: + type: string + required: true + default: "" + +# Include{containerConfig} +# Include{podOptions} +# Include{serviceRoot} +# Include{serviceMain} +# Include{serviceSelectorLoadBalancer} +# Include{serviceSelectorExtras} + - variable: main + label: "Main Service Port Configuration" + schema: + additional_attrs: true + type: dict + attrs: + - variable: port + label: "Port" + description: "This port exposes the container port on the service" + schema: + type: int + default: 9080 + required: true +# Include{serviceExpertRoot} +# Include{serviceExpert} +# Include{serviceList} +# Include{persistenceRoot} + - variable: data + label: App Data Storage + description: Stores the Application Data. + schema: + additional_attrs: true + type: dict + attrs: +# Include{persistenceBasic} +# Include{persistenceList} +# Include{ingressRoot} + - variable: main + label: "Main Ingress" + schema: + additional_attrs: true + type: dict + attrs: +# Include{ingressDefault} +# Include{ingressTLS} +# Include{ingressTraefik} +# Include{ingressAdvanced} +# Include{ingressList} +# Include{securityContextRoot} + + - variable: runAsUser + label: "runAsUser" + description: "The UserID of the user running the application" + schema: + type: int + default: 568 + - variable: runAsGroup + label: "runAsGroup" + description: "The groupID of the user running the application" + schema: + type: int + default: 568 +# Include{securityContextContainer} +# Include{securityContextAdvanced} +# Include{securityContextPod} + - variable: fsGroup + label: "fsGroup" + description: "The group that should own ALL storage." + schema: + type: int + default: 568 + +# Include{resources} +# Include{advanced} +# Include{addons} +# Include{codeserver} +# Include{netshoot} +# Include{vpn} +# Include{documentation} diff --git a/charts/incubator/answer/templates/NOTES.txt b/charts/incubator/answer/templates/NOTES.txt new file mode 100644 index 00000000000..efcb74cb772 --- /dev/null +++ b/charts/incubator/answer/templates/NOTES.txt @@ -0,0 +1 @@ +{{- include "tc.v1.common.lib.chart.notes" $ -}} diff --git a/charts/incubator/answer/templates/common.yaml b/charts/incubator/answer/templates/common.yaml new file mode 100644 index 00000000000..b51394e00a4 --- /dev/null +++ b/charts/incubator/answer/templates/common.yaml @@ -0,0 +1 @@ +{{ include "tc.v1.common.loader.all" . }} diff --git a/charts/incubator/answer/values.yaml b/charts/incubator/answer/values.yaml new file mode 100644 index 00000000000..8bd9c8496a5 --- /dev/null +++ b/charts/incubator/answer/values.yaml @@ -0,0 +1,81 @@ +image: + repository: tccr.io/truecharts/answer + pullPolicy: IfNotPresent + tag: v1.2.0@sha256:70a578170bca4a7a1040d44cb5ff143d5e9c2c2f32f9d48f1ad4519d61c35451 + + +service: + main: + ports: + main: + protocol: http + port: 9080 + +answer: + app: + language: en-US + # DEBUG | INFO | WARN | ERROR + log_level: DEBUG + site: + name: Answer + url: http://localhost:9080 + contact_email: contact@example.com + admin: + name: admin + password: super-secret-password + email: admin@example.com + +workload: + main: + podSpec: + containers: + main: + probes: + liveness: + path: /healthz + readiness: + path: /healthz + startup: + type: tcp + env: + AUTO_INSTALL: true + INSTALL_PORT: "{{ .Values.service.main.ports.main.port }}" + DB_TYPE: postgres + DB_USERNAME: "{{ .Values.cnpg.main.user }}" + DB_PASSWORD: + secretKeyRef: + name: cnpg-main-user + key: password + # Host + port + DB_HOST: '{{ printf "%s:5432" (.Values.cnpg.main.creds.host | trimAll "\"") }}' + DB_NAME: "{{ .Values.cnpg.main.database }}" + # App + LANGUAGE: "{{ .Values.answer.app.language }}" + LOG_LEVEL: "{{ .Values.answer.app.log_level }}" + # Site + SITE_NAME: "{{ .Values.answer.site.name }}" + SITE_URL: "{{ .Values.answer.site.url }}" + CONTACT_EMAIL: "{{ .Values.answer.site.contact_email }}" + # Admin + ADMIN_NAME: "{{ .Values.answer.admin.name }}" + ADMIN_PASSWORD: "{{ .Values.answer.admin.password }}" + ADMIN_EMAIL: "{{ .Values.answer.admin.email }}" + +persistence: + data: + enabled: true + mountPath: /data + +cnpg: + main: + enabled: true + user: answer + database: answer + +portal: + open: + enabled: true + +operator: + verify: + enabled: false