diff --git a/charts/incubator/pastey/Chart.yaml b/charts/incubator/pastey/Chart.yaml index 20e95f0804f..94b35507b1e 100644 --- a/charts/incubator/pastey/Chart.yaml +++ b/charts/incubator/pastey/Chart.yaml @@ -1,16 +1,11 @@ -annotations: - truecharts.org/SCALE-support: "true" - truecharts.org/catagories: | - - Productivity - - Tools-Utilities apiVersion: v2 -appVersion: "latest" +appVersion: "0.5.1" dependencies: - name: common repository: https://library-charts.truecharts.org - version: 11.1.2 + version: 12.14.6 deprecated: false -description: A lightweight, self-hosted paste platform (Pastebin alternative) with language detection and on-disk encryption. +description: A lightweight, self-hosted paste platform. home: https://truecharts.org/charts/incubator/pastey icon: https://truecharts.org/img/hotlink-ok/chart-icons/pastey.png keywords: @@ -27,4 +22,9 @@ sources: - https://github.com/truecharts/charts/tree/master/charts/incubator/pastey - https://github.com/Cesura/pastey type: application -version: 2.0.9 +version: 3.0.0 +annotations: + truecharts.org/catagories: | + - Productivity + - Tools-Utilities + truecharts.org/SCALE-support: "true" diff --git a/charts/incubator/pastey/ci/base-values.yaml b/charts/incubator/pastey/ci/base-values.yaml new file mode 100644 index 00000000000..7e36603e844 --- /dev/null +++ b/charts/incubator/pastey/ci/base-values.yaml @@ -0,0 +1 @@ +imageSelector: image diff --git a/charts/incubator/pastey/ci/slim-values.yaml b/charts/incubator/pastey/ci/slim-values.yaml new file mode 100644 index 00000000000..41e8ad98615 --- /dev/null +++ b/charts/incubator/pastey/ci/slim-values.yaml @@ -0,0 +1 @@ +imageSelector: slimImage diff --git a/charts/incubator/pastey/icon.png b/charts/incubator/pastey/icon.png index a8158ed350e..46b796024fb 100644 Binary files a/charts/incubator/pastey/icon.png and b/charts/incubator/pastey/icon.png differ diff --git a/charts/incubator/pastey/questions.yaml b/charts/incubator/pastey/questions.yaml index c6854391ca6..3593f5a084c 100644 --- a/charts/incubator/pastey/questions.yaml +++ b/charts/incubator/pastey/questions.yaml @@ -10,64 +10,110 @@ questions: # Include{replicas1} # Include{podSpec} # Include{containerMain} + + - variable: imageSelector + label: Select Image + schema: + type: string + default: image + enum: + - value: image + description: Image + - value: slimImage + description: Slim + + - variable: env + label: Image Environment + schema: + additional_attrs: true + type: dict + attrs: + - variable: PASTEY_BEHIND_PROXY + label: "Pastey Behind Proxy" + description: "Inform Pastey if it is behind a reverse proxy." + schema: + type: boolean + default: false + - variable: PASTEY_GUESS_THRESHOLD + label: "Pastey Guess Threshold" + description: "Threshold for automatic language detection guesses." + schema: + type: string + default: "0.20" + - variable: PASTEY_RATE_LIMIT + label: "Pastey Rate Limit" + description: "Rate limit for pasting, for non-whitelisted users." + schema: + type: string + default: "5/hour" + - variable: PASTEY_RECENT_PASTES + label: "Pastey Recent Pastes" + description: "Number of recent pastes to show on the home page." + schema: + type: int + default: 10 + - variable: PASTEY_RESTRICT_PASTING + label: "Pastey Restrict Pasting" + description: "Enable/disable restricting of pasting to whitelisted users." + schema: + type: boolean + default: false + - variable: PASTEY_RESTRICT_PASTING + label: "Pastey Restrict Pasting" + description: "Enable/disable restricting of pasting to whitelisted users." + schema: + type: boolean + default: false + - variable: PASTEY_USE_WHITELIST + label: "Pastey Use Whitelist" + description: "Enable/disable whitelisting for admin tasks." + schema: + type: boolean + default: true + - variable: PASTEY_WHITELIST_CIDR + label: "Pastey WhiteList CIDR" + description: "List of whitelisted IP addresses or networks." + schema: + type: string + default: "127.0.0.1/32,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16" + - variable: PASTEY_DEFAULT_THEME + label: "Pastey Default Theme" + schema: + type: string + default: "Dark" + enum: + - value: "Dark" + description: "Dark" + - value: "Light" + description: "Light" + - variable: PASTEY_PURGE_INTERVAL + label: "Pastey Purge Interval" + description: "Purge interval (in seconds) for checking expired pastes in background thread." + schema: + type: int + default: 10 + - variable: PASTEY_FORCE_SHOW_RECENT + label: "Pastey Force Show Recent" + description: "Show recent pastes on the home page, even to non-whitelisted users." + schema: + type: boolean + default: false + - variable: PASTEY_IGNORE_GUESS + label: "Pastey Ignore Guess" + description: "Ignore these classifications for language detection." + schema: + type: string + default: "TeX,SQL" + - variable: PASTEY_SHOW_CLI_BUTTON + label: "Pastey Show Cli Button" + description: "Enable/disabling showing of CLI button on home page." + schema: + type: boolean + default: true + # Include{containerBasic} # Include{containerAdvanced} - - variable: env - group: "App Configuration" - label: "Image Environment" - schema: - additional_attrs: true - type: dict - attrs: - - variable: PASTEY_RESTRICT_PASTING - label: "PASTEY_RESTRICT_PASTING" - description: "Enabledisable restricting of pasting to whitelisted users." - schema: - type: string - default: "False" - - variable: PASTEY_RESTRICT_RAW_PASTING - label: "PASTEY_RESTRICT_RAW_PASTING" - description: "Enabledisable restricting of pasting via raw to whitelisted users." - schema: - type: string - default: "True" - - variable: PASTEY_RATE_LIMIT - label: "PASTEY_RATE_LIMIT" - description: "Rate limit for pasting, for non-whitelisted users." - schema: - type: string - default: "5/hour" - - variable: PASTEY_RECENT_PASTES - label: "PASTEY_RECENT_PASTES" - description: "Number of recent pastes to show on the home page." - schema: - type: string - default: "10" - - variable: PASTEY_BEHIND_PROXY - label: "PASTEY_BEHIND_PROXY" - description: "Inform Pastey if it is behind a reverse proxy (nginx, etc.). If this is the case, it will rely on HTTP headers X-Real-IP or X-Forwarded-For. NOTE Make sure your proxy config sets these values." - schema: - type: string - default: "False" - - variable: PASTEY_USE_WHITELIST - label: "PASTEY_USE_WHITELIST" - description: "Enabledisable whitelisting for admin tasks (view recent, delete, config)." - schema: - type: string - default: "True" - - variable: PASTEY_WHITELIST_CIDR - label: "PASTEY_WHITELIST_CIDR" - description: "List of whitelisted IP addresses or networks (in CIDR format)." - schema: - type: string - default: "127.0.0.1/32,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16" - - variable: PASTEY_GUESS_THRESHOLD - label: "PASTEY_GUESS_THRESHOLD" - description: "Threshold for automatic language detection guesses. If a result is below this value, it is treated as Plaintext." - schema: - type: string - default: "0.20" # Include{containerConfig} # Include{serviceRoot} - variable: main @@ -97,8 +143,8 @@ questions: # Include{serviceList} # Include{persistenceRoot} - variable: data - label: "data Storage" - description: "Container Path appdata" + label: "App Data Storage" + description: "Stores the Application Data." schema: additional_attrs: true type: dict diff --git a/charts/incubator/pastey/templates/NOTES.txt b/charts/incubator/pastey/templates/NOTES.txt new file mode 100644 index 00000000000..efcb74cb772 --- /dev/null +++ b/charts/incubator/pastey/templates/NOTES.txt @@ -0,0 +1 @@ +{{- include "tc.v1.common.lib.chart.notes" $ -}} diff --git a/charts/incubator/pastey/templates/common.yaml b/charts/incubator/pastey/templates/common.yaml index cbf66c20818..b51394e00a4 100644 --- a/charts/incubator/pastey/templates/common.yaml +++ b/charts/incubator/pastey/templates/common.yaml @@ -1,2 +1 @@ -{{/* Render the templates */}} -{{ include "tc.common.loader.all" . }} +{{ include "tc.v1.common.loader.all" . }} diff --git a/charts/incubator/pastey/values.yaml b/charts/incubator/pastey/values.yaml index df283483485..65c60b3a64c 100644 --- a/charts/incubator/pastey/values.yaml +++ b/charts/incubator/pastey/values.yaml @@ -1,33 +1,64 @@ -env: - PASTEY_BEHIND_PROXY: "False" - PASTEY_GUESS_THRESHOLD: "0.20" - PASTEY_RATE_LIMIT: 5/hour - PASTEY_RECENT_PASTES: "10" - PASTEY_RESTRICT_PASTING: "False" - PASTEY_RESTRICT_RAW_PASTING: "True" - PASTEY_USE_WHITELIST: "True" - PASTEY_WHITELIST_CIDR: 127.0.0.1/32,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 image: pullPolicy: IfNotPresent repository: tccr.io/truecharts/pastey - tag: latest@sha256:636025eadb99257ec7cb21f7f519a52aed65fbd16b446f71d1d921850a6af996 -persistence: - data: - enabled: true - mountPath: /app/data -podSecurityContext: - runAsGroup: 0 - runAsUser: 0 + tag: v0.5.1@sha256:cc7d7e848fb023bcc1bf82a568421d2fcb5bd29eb23a5694c925e71662e725ab +slimImage: + pullPolicy: IfNotPresent + repository: tccr.io/truecharts/pastey-slim + tag: v0.5.1@sha256:acde8ecaf0216a57e1ee4e449884a09b9d8493bcb69185ed74436489dabbece5 + securityContext: - readOnlyRootFilesystem: false - runAsNonRoot: false + container: + runAsNonRoot: false + readOnlyRootFilesystem: false + runAsUser: 0 + runAsGroup: 0 + service: main: ports: main: + protocol: http port: 5000 - protocol: TCP - targetPort: 5000 + +workload: + main: + podSpec: + containers: + main: + imageSelector: image + probes: + liveness: + type: http + path: / + readiness: + type: http + path: / + startup: + type: http + path: / + env: + PASTEY_LISTEN_PORT: "{{ .Values.service.main.ports.main.port }}" + PASTEY_LISTEN_ADDRESS: "0.0.0.0" + PASTEY_BEHIND_PROXY: false + PASTEY_GUESS_THRESHOLD: "0.20" + PASTEY_RATE_LIMIT: 5/hour + PASTEY_RECENT_PASTES: "10" + PASTEY_RESTRICT_PASTING: false + PASTEY_USE_WHITELIST: true + PASTEY_WHITELIST_CIDR: 127.0.0.1/32,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 + # PASTEY_BLACKLIST_CIDR: "" + PASTEY_DEFAULT_THEME: "Dark" + PASTEY_PURGE_INTERVAL: 3600 + PASTEY_FORCE_SHOW_RECENT: false + PASTEY_IGNORE_GUESS: "TeX,SQL" + PASTEY_SHOW_CLI_BUTTON: true + +persistence: + data: + enabled: true + mountPath: /app/data portal: - enabled: true + open: + enabled: true