From 87f0cfc89dfb1fd2b50631164182400b3dda345e Mon Sep 17 00:00:00 2001 From: StevenMcElligott <89483932+StevenMcElligott@users.noreply.github.com> Date: Sun, 30 Apr 2023 04:58:08 -0400 Subject: [PATCH] feat(mongo-express): Add mongo-express (#8158) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit **Description** Add Mongo-Express, since we need something in the catalog to access/manage mongodb files in container format ⚒️ 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 - [X] ⬆️ 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. - [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> --- charts/incubator/mongo-express/.helmignore | 30 ++++ charts/incubator/mongo-express/CHANGELOG.md | 1 + charts/incubator/mongo-express/Chart.yaml | 35 +++++ charts/incubator/mongo-express/README.md | 27 ++++ .../mongo-express/ci/basic-values.yaml | 26 ++++ charts/incubator/mongo-express/icon.png | Bin 0 -> 17847 bytes charts/incubator/mongo-express/questions.yaml | 145 ++++++++++++++++++ .../mongo-express/templates/NOTES.txt | 1 + .../mongo-express/templates/common.yaml | 1 + charts/incubator/mongo-express/values.yaml | 53 +++++++ 10 files changed, 319 insertions(+) create mode 100644 charts/incubator/mongo-express/.helmignore create mode 100644 charts/incubator/mongo-express/CHANGELOG.md create mode 100644 charts/incubator/mongo-express/Chart.yaml create mode 100644 charts/incubator/mongo-express/README.md create mode 100644 charts/incubator/mongo-express/ci/basic-values.yaml create mode 100644 charts/incubator/mongo-express/icon.png create mode 100644 charts/incubator/mongo-express/questions.yaml create mode 100644 charts/incubator/mongo-express/templates/NOTES.txt create mode 100644 charts/incubator/mongo-express/templates/common.yaml create mode 100644 charts/incubator/mongo-express/values.yaml diff --git a/charts/incubator/mongo-express/.helmignore b/charts/incubator/mongo-express/.helmignore new file mode 100644 index 00000000000..77ca5567b26 --- /dev/null +++ b/charts/incubator/mongo-express/.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/mongo-express/CHANGELOG.md b/charts/incubator/mongo-express/CHANGELOG.md new file mode 100644 index 00000000000..8a802039f7f --- /dev/null +++ b/charts/incubator/mongo-express/CHANGELOG.md @@ -0,0 +1 @@ +## Changelog diff --git a/charts/incubator/mongo-express/Chart.yaml b/charts/incubator/mongo-express/Chart.yaml new file mode 100644 index 00000000000..f5f6e0f2d46 --- /dev/null +++ b/charts/incubator/mongo-express/Chart.yaml @@ -0,0 +1,35 @@ +apiVersion: v2 +appVersion: "latest" +dependencies: + - name: common + repository: https://library-charts.truecharts.org + version: 12.6.1 + - condition: mongodb.enabled + name: mongodb + repository: https://deps.truecharts.org/ + version: 6.0.15 +deprecated: false +description: mongo-express is a web-based MongoDB admin interface written in Node.js, Express.js, and Bootstrap3. +home: https://truecharts.org/charts/incubator +icon: https://truecharts.org/img/hotlink-ok/chart-icons/mongo-express.png +keywords: + - mongo + - mongodb + - database +kubeVersion: ">=1.16.0-0" +maintainers: + - email: info@truecharts.org + name: TrueCharts + url: https://truecharts.org +name: mongo-express +sources: + - https://github.com/truecharts/charts/tree/master/charts/incubator/mongo-express + - https://hub.docker.com/_/mongo-express/ + - https://github.com/mongo-express/mongo-express +type: application +version: 0.0.1 +annotations: + truecharts.org/catagories: | + - database + - utilities + truecharts.org/SCALE-support: "true" diff --git a/charts/incubator/mongo-express/README.md b/charts/incubator/mongo-express/README.md new file mode 100644 index 00000000000..701942c352f --- /dev/null +++ b/charts/incubator/mongo-express/README.md @@ -0,0 +1,27 @@ +# README + +## General Info + +TrueCharts can be installed as both *normal* Helm Charts or as Apps on TrueNAS SCALE. +However only installations using the TrueNAS SCALE Apps system are supported. + +For more information about this App, please check the docs on the TrueCharts [website](https://truecharts.org/charts/stable/) + +**This chart is not maintained by the upstream project and any issues with the chart should be raised [here](https://github.com/truecharts/charts/issues/new/choose)** + + +## Support + +- Please check our [quick-start guides for TrueNAS SCALE](https://truecharts.org/manual/SCALE%20Apps/Important-MUST-READ). +- See the [Website](https://truecharts.org) +- Check our [Discord](https://discord.gg/tVsPTHWTtr) +- Open a [issue](https://github.com/truecharts/charts/issues/new/choose) + +--- + +## Sponsor TrueCharts + +TrueCharts can only exist due to the incredible effort of our staff. +Please consider making a [donation](https://truecharts.org/sponsor) or contributing back to the project any way you can! + +*All Rights Reserved - The TrueCharts Project* diff --git a/charts/incubator/mongo-express/ci/basic-values.yaml b/charts/incubator/mongo-express/ci/basic-values.yaml new file mode 100644 index 00000000000..225ea0375fd --- /dev/null +++ b/charts/incubator/mongo-express/ci/basic-values.yaml @@ -0,0 +1,26 @@ +mongodb: + enabled: true + mongodbUsername: mongoexpress + mongodbDatabase: mongoexpress + +workload: + main: + podSpec: + containers: + main: + env: + ME_CONFIG_MONGODB_PORT: 27017 + ME_CONFIG_MONGODB_AUTH_DATABASE: "{{ .Values.mongodb.mongodbDatabase }}" + ME_CONFIG_MONGODB_AUTH_USERNAME: "{{ .Values.mongodb.mongodbUsername }}" + ME_CONFIG_BASICAUTH_USERNAME: admin + ME_CONFIG_BASICAUTH_PASSWORD: pass + ME_CONFIG_MONGODB_SERVER: + secretKeyRef: + expandObjectName: false + name: '{{ printf "%s-%s" .Release.Name "mongodbcreds" }}' + key: plainhost + ME_CONFIG_MONGODB_AUTH_PASSWORD: + secretKeyRef: + expandObjectName: false + name: '{{ printf "%s-%s" .Release.Name "mongodbcreds" }}' + key: mongodb-password diff --git a/charts/incubator/mongo-express/icon.png b/charts/incubator/mongo-express/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..339762f06264a0b17e510a967bf09874a3482361 GIT binary patch literal 17847 zcmeI4c|4Ts`^TR#s2o&^qe9bY#h4jp%osDYAPL#B6f$NWjAdq;g|XGpLc3EG=}?Il zB}`G*6QXRDqwh0FdaC)I@9X>h{eJ(xlnHapxTJIbVfKRKm~yzEH(}Oy6Pet#bVOX-b81dGj|CX z%5sS1fgZ6go{ZRVh9whiW35INQ6PaxP(VkCA|u#*iin0D(xpJZWzASLYN(4KoQ7T` z8xZB=?21~#;ejZkDG|fK;Rz^`r750>Cy?|I5GYZa4nqoEgT9;0fiS8T5xY#*rvE+!&GJo-hq(4wDre^9>DiGYZ~ftj3t0a1ChdFzEvN zKT;XncZ?2`K?&yYBIyEaRwO+H#B$joRP5)*F+E2Uin4?g!Qnxd1zMX^vEOPQ6E&1% zlx1wbfX-%s%WSQo22&P`NioL-1u-qiBn%yA$;5zo0s%uO1Q9SKOFEta;z>Ay1#<|Z zv-8;SucU1`454hJj7T#fX%c}+BGDO441vxdVuDBn5EB$kqGJezUB#Rl^v=ll+R>-Uwvb_L8fWK({d|9KBBVnws7x14^9@ZZd{{1nc zLqWE@4K*w^)a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wqTOPSYKc2jxyFd>dE|F0x^B%Sw#P3E ztCCtC(+-%}fZFHmoX^|qv&*ySS^NF$M6-*gtggv-lbEiUC#pK%R=By(T@9%BXnciKZl^J)kOFdRxirCZb{O z{^m)mCQ4RHeB5fvz-%LNNY~m5joSJwZKaE<9rxCf?D}l06S9w;Bs|Htaw{jC1*`Ml zJh=lXk4fQ@0e_HLla`n!grBv+= z+x<6J)*iq1>{+^>q;cWSM?ZS06Jkl7=54_@@;$|s_&!rZ(?Z>d_*u9~+cb{cbt|xo zSD%5;&5+t^hmoFOi$Clk`cLi>P2RAN=j9{_Gj7$1#UwE6R3|5&3T|=2->WbSq_+AT zzNDjC=Gsp)m~vEQ0fHB`PqcMSIATuZzRuF4ZYswEmDRc9gpw$u*5+3;bdYh#4C8^g z75&SXE1i5fy>o7=`t`+wzB|B6yO@D<4OH{Wr%Lu;O|)F7)q1dG!|p`d{5BV@b;`A2 zrjCqV=rSTc%^nSLI zVC#J8?A(qMC-l{Btr|FKr=RCz{3!jt8+vCDqSu5Xe4yg^aR%VB!sl7HC4IZ>U#l#$ LbFnR49GLVk6bOEP literal 0 HcmV?d00001 diff --git a/charts/incubator/mongo-express/questions.yaml b/charts/incubator/mongo-express/questions.yaml new file mode 100644 index 00000000000..b76758ea6e2 --- /dev/null +++ b/charts/incubator/mongo-express/questions.yaml @@ -0,0 +1,145 @@ +# Include{groups} +portals: + open: +# Include{portalLink} +questions: +# Include{global} +# Include{workload} +# Include{workloadDeployment} + +# Include{replicas1} +# Include{podSpec} +# Include{containerMain} + - variable: env + group: App Configuration + label: Image Environment + schema: + additional_attrs: true + type: dict + attrs: + - variable: ME_CONFIG_BASICAUTH_USERNAME + label: WebUI Basic Auth Username + description: Basic Auth Username + schema: + type: string + default: "" + required: true + - variable: ME_CONFIG_BASICAUTH_PASSWORD + label: WebUI Basic Auth Password + description: Basic Auth Password + schema: + type: string + default: "" + required: true + private: true + - variable: ME_CONFIG_MONGODB_SERVER + label: MongoDB Database Server + description: Database Server + schema: + type: string + default: "" + - variable: ME_CONFIG_MONGODB_PORT + label: MongoDB Database Port + description: Database Port + schema: + type: int + default: 27017 + - variable: ME_CONFIG_MONGODB_AUTH_DATABASE + label: MongoDB Database name + description: Database name + schema: + type: string + required: true + default: mongo-express + - variable: ME_CONFIG_MONGODB_AUTH_USERNAME + label: MongoDB Database username + description: Database username + schema: + type: string + required: true + default: mongo-express + - variable: ME_CONFIG_MONGODB_AUTH_PASSWORD + label: MongoDB Database Password + description: Database password + schema: + type: string + default: "" + private: true + - variable: ME_CONFIG_OPTIONS_EDITORTHEME + label: Editor Theme + description: Pick a theme from https://codemirror.net/5/demo/theme.html + schema: + type: string + required: true + default: default + +# Include{containerBasic} +# Include{containerAdvanced} + +# Include{containerConfig} +# 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: 18081 + required: true +# Include{serviceExpertRoot} + default: false +# Include{serviceExpert} +# Include{serviceList} +# Include{persistenceRoot} +# 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{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 this App 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/mongo-express/templates/NOTES.txt b/charts/incubator/mongo-express/templates/NOTES.txt new file mode 100644 index 00000000000..efcb74cb772 --- /dev/null +++ b/charts/incubator/mongo-express/templates/NOTES.txt @@ -0,0 +1 @@ +{{- include "tc.v1.common.lib.chart.notes" $ -}} diff --git a/charts/incubator/mongo-express/templates/common.yaml b/charts/incubator/mongo-express/templates/common.yaml new file mode 100644 index 00000000000..b51394e00a4 --- /dev/null +++ b/charts/incubator/mongo-express/templates/common.yaml @@ -0,0 +1 @@ +{{ include "tc.v1.common.loader.all" . }} diff --git a/charts/incubator/mongo-express/values.yaml b/charts/incubator/mongo-express/values.yaml new file mode 100644 index 00000000000..cd7e7c3f0bf --- /dev/null +++ b/charts/incubator/mongo-express/values.yaml @@ -0,0 +1,53 @@ +image: + repository: docker.io/mongo-express + pullPolicy: IfNotPresent + tag: latest@sha256:d5cee110909938c99cf8800b9379494c190d8fecaec70a4ce3886facdee6ef8e + +service: + main: + ports: + main: + protocol: http + targetPort: 8081 + port: 18081 + +securityContext: + container: + readOnlyRootFilesystem: false + +workload: + main: + podSpec: + containers: + main: + probes: + liveness: + type: http + httpHeaders: + Authorization: '{{ printf "Basic %s" ((printf "%s:%s" .Values.workload.main.podSpec.containers.main.env.ME_CONFIG_BASICAUTH_USERNAME .Values.workload.main.podSpec.containers.main.env.ME_CONFIG_BASICAUTH_PASSWORD) | b64enc) }}' + readiness: + type: http + httpHeaders: + Authorization: '{{ printf "Basic %s" ((printf "%s:%s" .Values.workload.main.podSpec.containers.main.env.ME_CONFIG_BASICAUTH_USERNAME .Values.workload.main.podSpec.containers.main.env.ME_CONFIG_BASICAUTH_PASSWORD) | b64enc) }}' + startup: + type: http + httpHeaders: + Authorization: '{{ printf "Basic %s" ((printf "%s:%s" .Values.workload.main.podSpec.containers.main.env.ME_CONFIG_BASICAUTH_USERNAME .Values.workload.main.podSpec.containers.main.env.ME_CONFIG_BASICAUTH_PASSWORD) | b64enc) }}' + + env: + ME_CONFIG_MONGODB_PORT: "" + ME_CONFIG_MONGODB_SERVER: "" + ME_CONFIG_BASICAUTH_USERNAME: "" + ME_CONFIG_BASICAUTH_PASSWORD: "" + # https://codemirror.net/5/demo/theme.html + ME_CONFIG_OPTIONS_EDITORTHEME: default + ME_CONFIG_MONGODB_AUTH_DATABASE: "" + ME_CONFIG_MONGODB_AUTH_USERNAME: "" + ME_CONFIG_MONGODB_AUTH_PASSWORD: "" + +mongodb: + enabled: false + +portal: + open: + enabled: true