WIP Cleanup configuration options (#4365)

* chore(apps): remove un-needed UI elements

* dont grab metallb upstreams anymore

* add new readme template pointing to the website and remove helm-values system

* Move readme generation to daily job

* remove readme addition and remve readme generation from build-release script

* bump

* remvoe the use of helm-docs

* completely remove helm-docs

* move tag sync to renovate bump action

* fully remove tag sync and remove needless helm dependency updates

* remove needless helm prep

* get rid of needlessly loaded grafana repo
This commit is contained in:
Kjeld Schouten-Lebbing 2022-11-10 16:46:44 +01:00 committed by GitHub
parent 78626622e7
commit 5864fce3ac
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
45 changed files with 290 additions and 1284 deletions

View File

@ -54,6 +54,5 @@ chart-repos:
- truecharts=https://charts.truecharts.org - truecharts=https://charts.truecharts.org
- truecharts-library=https://library-charts.truecharts.org - truecharts-library=https://library-charts.truecharts.org
- bitnami=https://charts.bitnami.com/bitnami - bitnami=https://charts.bitnami.com/bitnami
- metallb=https://metallb.github.io/metallb
- grafana=https://grafana.github.io/helm-charts - grafana=https://grafana.github.io/helm-charts
- prometheus=https://prometheus-community.github.io/helm-charts - prometheus=https://prometheus-community.github.io/helm-charts

View File

@ -16,6 +16,5 @@ chart-repos:
- truecharts=https://charts.truecharts.org - truecharts=https://charts.truecharts.org
- truecharts-library=https://library-charts.truecharts.org - truecharts-library=https://library-charts.truecharts.org
- bitnami=https://charts.bitnami.com/bitnami - bitnami=https://charts.bitnami.com/bitnami
- metallb=https://metallb.github.io/metallb
- grafana=https://grafana.github.io/helm-charts - grafana=https://grafana.github.io/helm-charts
- prometheus=https://prometheus-community.github.io/helm-charts - prometheus=https://prometheus-community.github.io/helm-charts

View File

@ -37,21 +37,6 @@ clean_catalog() {
} }
export -f clean_catalog export -f clean_catalog
prep_helm() {
if [[ -z "$standalone" ]]; then
helm repo add truecharts-old https://truecharts.org
helm repo add truecharts https://charts.truecharts.org
helm repo add truecharts-library https://library-charts.truecharts.org
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add metallb https://metallb.github.io/metallb
helm repo add grafana https://grafana.github.io/helm-charts
helm repo add prometheus https://prometheus-community.github.io/helm-charts
helm repo add amd-gpu-helm https://radeonopencompute.github.io/k8s-device-plugin/
helm repo update
fi
}
export -f prep_helm
clean_apps() { clean_apps() {
local chart="$1" local chart="$1"
local chartname="$2" local chartname="$2"

View File

@ -3,62 +3,6 @@ set -o errexit
set -o nounset set -o nounset
set -o pipefail set -o pipefail
# Designed to ensure the appversion in Chart.yaml is in sync with the primary Chart tag if found
# Also makes sure that home link is pointing to the correct url
sync_tag() {
local chart="$1"
local chartname="$2"
local train="$3"
local chartversion="$4"
echo "Attempting to sync primary tag with appversion for: ${chartname}"
local tag="$(cat ${chart}/values.yaml | grep '^ tag: ' | awk -F" " '{ print $2 }' | head -1)"
tag="${tag%%@*}"
tag="${tag:-auto}"
tag=$(echo $tag | sed "s/release-//g")
tag=$(echo $tag | sed "s/release_//g")
tag=$(echo $tag | sed "s/version-//g")
tag=$(echo $tag | sed "s/version_//g")
tag="${tag#*V.}"
tag="${tag#*v-}"
tag="${tag#*v}"
tag="${tag%-*}"
tag="${tag:0:10}"
tag="${tag%-}"
tag="${tag%_}"
tag="${tag%.}"
echo "Updating tag of ${chartname} to ${tag}..."
sed -i -e "s|appVersion: .*|appVersion: \"${tag}\"|" "${chart}/Chart.yaml"
echo "Updating icon of ${chartname}..."
sed -i -e "s|icon: .*|icon: https:\/\/truecharts.org\/img\/hotlink-ok\/chart-icons\/${chartname}.png|" "${chart}/Chart.yaml"
echo "Updating home of ${chartname}..."
sed -i -e "s|home: .*|home: https:\/\/truecharts.org\/docs\/charts\/${train}\/${chartname}|" "${chart}/Chart.yaml"
echo "Attempting to update sources of ${chartname}..."
echo "Using go-yq verion: <$(go-yq -V)>"
# Get all sources (except truecharts)
curr_sources=$(go-yq '.sources[] | select(. != "https://github.com/truecharts*")' "${chart}/Chart.yaml")
# Empty sources list in-place
go-yq -i 'del(.sources.[])' "${chart}/Chart.yaml"
# Add truechart source
tcsource="https://github.com/truecharts/charts/tree/master/charts/$train/$chartname" go-yq -i '.sources += env(tcsource)' "${chart}/Chart.yaml"
# Add the rest of the sources
while IFS= read -r line; do
src="$line" go-yq -i '.sources += env(src)' "${chart}/Chart.yaml"
done <<< "$curr_sources"
echo "Sources of ${chartname} updated!"
}
export -f sync_tag
sync_helmignore() {
local chart="$1"
local chartname="$2"
local train="$3"
local chartversion="$4"
echo "Attempting to sync HelmIgnore file for: ${chartname}"
rm -rf ${chart}/.helmignore
cp templates/chart/.helmignore ${chart}/
}
export -f sync_helmignore
create_changelog() { create_changelog() {
local chart="$1" local chart="$1"
local chartname="$2" local chartname="$2"
@ -82,21 +26,6 @@ create_changelog() {
} }
export -f create_changelog export -f create_changelog
generate_docs() {
local chart="$1"
local chartname="$2"
local train="$3"
local chartversion="$4"
echo "Generating Docs"
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="README.md" \
--template-files="/__w/charts/charts/templates/docs/README.md.gotmpl" \
--chart-search-root="${chart}"
sed -i "s/TRAINPLACEHOLDER/${train}/" "${chart}/README.md"
}
export -f generate_docs
if [[ -d "charts/${1}" ]]; then if [[ -d "charts/${1}" ]]; then
echo "Start processing charts/${1} ..." echo "Start processing charts/${1} ..."
@ -104,11 +33,7 @@ if [[ -d "charts/${1}" ]]; then
chartname=$(basename charts/${1}) chartname=$(basename charts/${1})
train=$(basename $(dirname "charts/${1}")) train=$(basename $(dirname "charts/${1}"))
SCALESUPPORT=$(cat charts/${1}/Chart.yaml | yq '.annotations."truecharts.org/SCALE-support"' -r) SCALESUPPORT=$(cat charts/${1}/Chart.yaml | yq '.annotations."truecharts.org/SCALE-support"' -r)
sync_helmignore "charts/${1}" "${chartname}" "$train" "${chartversion}" || echo "Syncing HelmIgnore file failed..."
helm dependency update "charts/${1}" --skip-refresh || (sleep 10 && helm dependency update "charts/${1}" --skip-refresh) || (sleep 10 && helm dependency update "charts/${1}" --skip-refresh)
sync_tag "charts/${1}" "${chartname}" "$train" "${chartversion}" || echo "Tag sync failed..."
create_changelog "charts/${1}" "${chartname}" "$train" "${chartversion}" || echo "changelog generation failed..." create_changelog "charts/${1}" "${chartname}" "$train" "${chartversion}" || echo "changelog generation failed..."
generate_docs "charts/${1}" "${chartname}" "$train" "${chartversion}" || echo "Docs generation failed..."
else else
echo "Chart 'charts/${1}' no longer exists in repo. Skipping it..." echo "Chart 'charts/${1}' no longer exists in repo. Skipping it..."
fi fi

View File

@ -25,18 +25,12 @@ jobs:
helmv3 helmv3
helm: "3.8.0" helm: "3.8.0"
- name: Install helm-docs
run: |
wget -O /tmp/helm-docs.deb https://github.com/k8s-at-home/helm-docs/releases/download/v0.1.1/helm-docs_0.1.1_Linux_x86_64.deb
sudo dpkg -i /tmp/helm-docs.deb
- name: Prep Helm - name: Prep Helm
run: | run: |
helm repo add truecharts https://charts.truecharts.org helm repo add truecharts https://charts.truecharts.org
helm repo add truecharts-library https://library-charts.truecharts.org helm repo add truecharts-library https://library-charts.truecharts.org
helm repo add bitnami https://charts.bitnami.com/bitnami helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add metallb https://metallb.github.io/metallb
helm repo add grafana https://grafana.github.io/helm-charts
helm repo add prometheus https://prometheus-community.github.io/helm-charts helm repo add prometheus https://prometheus-community.github.io/helm-charts
helm repo update helm repo update
@ -97,7 +91,6 @@ jobs:
echo "copying docs to website for ${chart}" echo "copying docs to website for ${chart}"
rm -rf website/docs/charts/*/${chart} rm -rf website/docs/charts/*/${chart}
mkdir -p website/docs/charts/${train}/${chart} || echo "chart path already exists, continuing..." mkdir -p website/docs/charts/${train}/${chart} || echo "chart path already exists, continuing..."
yes | cp -rf charts/${train}/${chart}/README.md website/docs/charts/${train}/${chart}/index.md 2>/dev/null || :
yes | cp -rf charts/${train}/${chart}/CHANGELOG.md website/docs/charts/${train}/${chart}/CHANGELOG.md 2>/dev/null || : yes | cp -rf charts/${train}/${chart}/CHANGELOG.md website/docs/charts/${train}/${chart}/CHANGELOG.md 2>/dev/null || :
yes | cp -rf charts/${train}/${chart}/docs/* website/docs/charts/${train}/${chart}/ 2>/dev/null || : yes | cp -rf charts/${train}/${chart}/docs/* website/docs/charts/${train}/${chart}/ 2>/dev/null || :
yes | cp -rf charts/${train}/${chart}/icon.png website/static/img/hotlink-ok/chart-icons/${chart}.png 2>/dev/null || : yes | cp -rf charts/${train}/${chart}/icon.png website/static/img/hotlink-ok/chart-icons/${chart}.png 2>/dev/null || :
@ -173,7 +166,7 @@ jobs:
git push git push
cd - cd -
rm -rf catalog rm -rf catalog
release-helm-important: release-helm-important:
runs-on: ubuntu-latest runs-on: ubuntu-latest
container: container:
@ -187,17 +180,12 @@ jobs:
helmv3 helmv3
helm: "3.8.0" helm: "3.8.0"
- name: Install helm-docs
run: |
wget -O /tmp/helm-docs.deb https://github.com/k8s-at-home/helm-docs/releases/download/v0.1.1/helm-docs_0.1.1_Linux_x86_64.deb
sudo dpkg -i /tmp/helm-docs.deb
- name: Prep Helm - name: Prep Helm
run: | run: |
helm repo add truecharts https://charts.truecharts.org helm repo add truecharts https://charts.truecharts.org
helm repo add truecharts-library https://library-charts.truecharts.org helm repo add truecharts-library https://library-charts.truecharts.org
helm repo add bitnami https://charts.bitnami.com/bitnami helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add metallb https://metallb.github.io/metallb
helm repo add grafana https://grafana.github.io/helm-charts
helm repo add prometheus https://prometheus-community.github.io/helm-charts helm repo add prometheus https://prometheus-community.github.io/helm-charts
helm repo update helm repo update
- name: Checkout - name: Checkout
@ -239,7 +227,7 @@ jobs:
env: env:
CR_TOKEN: "${{ secrets.BOT_TOKEN }}" CR_TOKEN: "${{ secrets.BOT_TOKEN }}"
CR_SKIP_EXISTING: "true" CR_SKIP_EXISTING: "true"
release-helm-stable: release-helm-stable:
runs-on: ubuntu-latest runs-on: ubuntu-latest
container: container:
@ -253,17 +241,12 @@ jobs:
helmv3 helmv3
helm: "3.8.0" helm: "3.8.0"
- name: Install helm-docs
run: |
wget -O /tmp/helm-docs.deb https://github.com/k8s-at-home/helm-docs/releases/download/v0.1.1/helm-docs_0.1.1_Linux_x86_64.deb
sudo dpkg -i /tmp/helm-docs.deb
- name: Prep Helm - name: Prep Helm
run: | run: |
helm repo add truecharts https://charts.truecharts.org helm repo add truecharts https://charts.truecharts.org
helm repo add truecharts-library https://library-charts.truecharts.org helm repo add truecharts-library https://library-charts.truecharts.org
helm repo add bitnami https://charts.bitnami.com/bitnami helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add metallb https://metallb.github.io/metallb
helm repo add grafana https://grafana.github.io/helm-charts
helm repo add prometheus https://prometheus-community.github.io/helm-charts helm repo add prometheus https://prometheus-community.github.io/helm-charts
helm repo update helm repo update
- name: Checkout - name: Checkout
@ -292,7 +275,7 @@ jobs:
env: env:
CR_TOKEN: "${{ secrets.BOT_TOKEN }}" CR_TOKEN: "${{ secrets.BOT_TOKEN }}"
CR_SKIP_EXISTING: "true" CR_SKIP_EXISTING: "true"
release-helm-incubator: release-helm-incubator:
runs-on: ubuntu-latest runs-on: ubuntu-latest
container: container:
@ -315,8 +298,8 @@ jobs:
helm repo add truecharts https://charts.truecharts.org helm repo add truecharts https://charts.truecharts.org
helm repo add truecharts-library https://library-charts.truecharts.org helm repo add truecharts-library https://library-charts.truecharts.org
helm repo add bitnami https://charts.bitnami.com/bitnami helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add metallb https://metallb.github.io/metallb
helm repo add grafana https://grafana.github.io/helm-charts
helm repo add prometheus https://prometheus-community.github.io/helm-charts helm repo add prometheus https://prometheus-community.github.io/helm-charts
helm repo update helm repo update
- name: Checkout - name: Checkout

48
.github/workflows/daily.yaml vendored Normal file
View File

@ -0,0 +1,48 @@
name: "Daily Tasks"
on:
workflow_dispatch:
jobs:
generate-readme:
runs-on: ubuntu-latest
name: "Generate readme files"
steps:
- name: Checkout
uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # tag=v3
with:
token: ${{ secrets.BOT_TOKEN }}
fetch-depth: 0
- name: generate readme.md
shell: bash
run: |
for train in stable SCALE incubator games enterprise develop non-free deprecated dependency core; do
for chart in charts/${train}/*; do
if [ -d "${chart}" ]; then
echo "Generating readme.md for ${train}/${chart}"
cp "templates/README.md.tpl" "${chart}/README.md"
sed -i "s/TRAINPLACEHOLDER/${train}/" "${chart}/README.md"
sed -i "s/CHARTPLACEHOLDER/${chartname}/" "${chart}/README.md"
fi
done
done
- name: generate HelmIgnore
shell: bash
run: |
for train in stable SCALE incubator games enterprise develop non-free deprecated dependency core; do
for chart in charts/${train}/*; do
if [ -d "${chart}" ]; then
echo "Attempting to sync HelmIgnore file for: ${chartname}"
rm -rf ${chart}/.helmignore
cp templates/chart/.helmignore ${chart}/
fi
done
done
- name: Commit changes
run: |
git config user.name "TrueCharts-Bot"
git config user.email "bot@truecharts.org"
git add --all
git commit -sm "Commit daily changes" || exit 0
git push

View File

@ -41,6 +41,52 @@ jobs:
run: echo '${{ toJson(steps.filter.outputs) }}' > changes.json run: echo '${{ toJson(steps.filter.outputs) }}' > changes.json
- name: Bump - name: Bump
run: | run: |
# Designed to ensure the appversion in Chart.yaml is in sync with the primary Chart tag if found
# Also makes sure that home link is pointing to the correct url
sync_tag() {
local chart="$1"
local chartname="$2"
local train="$3"
echo "Attempting to sync primary tag with appversion for: ${chartname}"
local tag="$(cat ${chart}/values.yaml | grep '^ tag: ' | awk -F" " '{ print $2 }' | head -1)"
tag="${tag%%@*}"
tag="${tag:-auto}"
tag=$(echo $tag | sed "s/release-//g")
tag=$(echo $tag | sed "s/release_//g")
tag=$(echo $tag | sed "s/version-//g")
tag=$(echo $tag | sed "s/version_//g")
tag="${tag#*V.}"
tag="${tag#*v-}"
tag="${tag#*v}"
tag="${tag%-*}"
tag="${tag:0:10}"
tag="${tag%-}"
tag="${tag%_}"
tag="${tag%.}"
echo "Updating tag of ${chartname} to ${tag}..."
sed -i -e "s|appVersion: .*|appVersion: \"${tag}\"|" "${chart}/Chart.yaml"
echo "Updating icon of ${chartname}..."
sed -i -e "s|icon: .*|icon: https:\/\/truecharts.org\/img\/hotlink-ok\/chart-icons\/${chartname}.png|" "${chart}/Chart.yaml"
echo "Updating home of ${chartname}..."
sed -i -e "s|home: .*|home: https:\/\/truecharts.org\/docs\/charts\/${train}\/${chartname}|" "${chart}/Chart.yaml"
echo "Attempting to update sources of ${chartname}..."
echo "Using go-yq verion: <$(go-yq -V)>"
# Get all sources (except truecharts)
curr_sources=$(go-yq '.sources[] | select(. != "https://github.com/truecharts*")' "${chart}/Chart.yaml")
# Empty sources list in-place
go-yq -i 'del(.sources.[])' "${chart}/Chart.yaml"
# Add truechart source
tcsource="https://github.com/truecharts/charts/tree/master/charts/$train/$chartname" go-yq -i '.sources += env(tcsource)' "${chart}/Chart.yaml"
# Add the rest of the sources
while IFS= read -r line; do
src="$line" go-yq -i '.sources += env(src)' "${chart}/Chart.yaml"
done <<< "$curr_sources"
echo "Sources of ${chartname} updated!"
}
export -f sync_tag
# The actual script
APPS=$(jq --raw-output '.changed_files | fromjson | .[] |= sub("(?<filepath>(?<first_directory>(?<root1>[\/]?)[^\/]+\/)(?<second_directory>(?<root2>[\/]?)[^\/]+\/)(?<third_directory>(?<root3>[\/]?)[^\/]+)(?<extra_paths>.+))"; "\(.third_directory)") | unique' changes.json | jq -r '.[]') APPS=$(jq --raw-output '.changed_files | fromjson | .[] |= sub("(?<filepath>(?<first_directory>(?<root1>[\/]?)[^\/]+\/)(?<second_directory>(?<root2>[\/]?)[^\/]+\/)(?<third_directory>(?<root3>[\/]?)[^\/]+)(?<extra_paths>.+))"; "\(.third_directory)") | unique' changes.json | jq -r '.[]')
echo "changed apps: ${APPS[*]}" echo "changed apps: ${APPS[*]}"
for chart in ${APPS[*]} for chart in ${APPS[*]}
@ -78,6 +124,8 @@ jobs:
echo "Bumping patch version for ${train}/${chart}" echo "Bumping patch version for ${train}/${chart}"
./tools/bump.sh patch ./charts/${train}/${chart} ./tools/bump.sh patch ./charts/${train}/${chart}
fi fi
sync_tag "charts/${train}/${chart}" "${chart}" "${train}"
done done
- name: Cleanup - name: Cleanup
run: | run: |

1
.gitignore vendored
View File

@ -54,4 +54,3 @@ chartsrepo/
.cr-index/ .cr-index/
website/ website/
pub/ pub/
readme.md

View File

@ -22,7 +22,7 @@ sources:
- https://github.com/truecharts/charts/tree/master/charts/stable/jackett - https://github.com/truecharts/charts/tree/master/charts/stable/jackett
- https://github.com/Jackett/Jackett - https://github.com/Jackett/Jackett
type: application type: application
version: 11.0.130 version: 11.1.0
annotations: annotations:
truecharts.org/catagories: | truecharts.org/catagories: |
- media - media

27
templates/README.md.tpl Normal file
View File

@ -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/docs/charts/TRAINPLACEHOLDER/CHARTPLACEHOLDER)
**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/docs/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/apps/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*

27
templates/docs/README.md Normal file
View File

@ -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/docs/charts/TRAINPLACEHOLDER/CHARTPLACEHOLDER)
**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/docs/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/apps/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*

View File

@ -1,36 +0,0 @@
- variable: netshoot
label: Netshoot
schema:
additional_attrs: true
type: dict
attrs:
- variable: enabled
label: Enabled
schema:
type: boolean
default: false
show_subquestions_if: true
subquestions:
- variable: envList
label: Netshoot Environment Variables
schema:
type: list
show_if: [["type", "!=", "disabled"]]
default: []
items:
- variable: envItem
label: Environment Variable
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
required: true
- variable: value
label: Value
schema:
type: string
required: true

View File

@ -1,69 +0,0 @@
- variable: promtail
label: Promtail
schema:
additional_attrs: true
type: dict
attrs:
- variable: enabled
label: Enabled
schema:
type: boolean
default: false
show_subquestions_if: true
subquestions:
- variable: loki
label: Loki URL
schema:
type: string
required: true
- variable: logs
label: Log Paths
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
required: true
- variable: path
label: Path
schema:
type: string
required: true
- variable: args
label: Promtail Command Line Arguments
schema:
type: list
show_if: [["type", "!=", "disabled"]]
default: []
items:
- variable: arg
label: Arg
schema:
type: string
required: true
- variable: envList
label: Promtail Environment Variables
schema:
type: list
show_if: [["type", "!=", "disabled"]]
default: []
items:
- variable: envItem
label: Environment Variable
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
required: true
- variable: value
label: Value
schema:
type: string
required: true

View File

@ -1,27 +1,8 @@
- variable: controller - variable: controller
group: Controller group: "General Settings"
label: "" label: ""
schema: schema:
additional_attrs: true additional_attrs: true
type: dict type: dict
attrs: attrs:
- variable: advanced
label: Show Advanced Controller Settings
schema:
type: boolean
default: false
show_subquestions_if: true
subquestions:
- variable: type
description: Please specify type of workload to deploy
label: (Advanced) Controller Type
schema:
type: string
required: true
enum:
- value: deployment
description: Deployment
- value: statefulset
description: Statefulset
- value: daemonset
description: Daemonset

View File

@ -1 +0,0 @@
default: daemonset

View File

@ -1 +0,0 @@
default: deployment

View File

@ -1,47 +0,0 @@
- variable: expert
label: Show Expert Configuration Options
schema:
type: boolean
default: false
show_subquestions_if: true
subquestions:
- variable: labelsList
label: Controller Labels
schema:
type: list
default: []
items:
- variable: labelItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string
- variable: annotationsList
label: Controller Annotations
schema:
type: list
default: []
items:
- variable: annotationItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string

View File

@ -1,5 +1,5 @@
- variable: customcommand - variable: customcommand
group: Controller group: "General Settings"
label: "Custom Command" label: "Custom Command"
description: "Do not click this unless you know what you are doing" description: "Do not click this unless you know what you are doing"
schema: schema:

View File

@ -1,5 +1,5 @@
- variable: customextraargs - variable: customextraargs
group: Controller group: "General Settings"
label: "Extra Args" label: "Extra Args"
description: "Do not click this unless you know what you are doing" description: "Do not click this unless you know what you are doing"
schema: schema:

View File

@ -1 +0,0 @@
default: statefulset

View File

@ -1,6 +1,6 @@
- variable: TZ - variable: TZ
label: Timezone label: Timezone
group: Container Configuration group: "General Settings"
schema: schema:
type: string type: string
default: "Etc/UTC" default: "Etc/UTC"
@ -9,7 +9,7 @@
- variable: envList - variable: envList
label: Extra Environment Variables label: Extra Environment Variables
description: "Please be aware that some variables are set in the background, adding duplicates here might cause issues or prevent the app from starting..." description: "Please be aware that some variables are set in the background, adding duplicates here might cause issues or prevent the app from starting..."
group: Container Configuration group: "General Settings"
schema: schema:
type: list type: list
default: [] default: []
@ -28,79 +28,3 @@
label: Value label: Value
schema: schema:
type: string type: string
- variable: expertpodconf
group: Container Configuration
label: Show Expert Configuration
schema:
type: boolean
default: false
show_subquestions_if: true
subquestions:
- variable: tty
label: Enable TTY
description: Determines whether containers in a pod runs with TTY enabled. By default pod has it disabled.
group: Workload Details
schema:
type: boolean
default: false
- variable: stdin
label: Enable STDIN
description: Determines whether containers in a pod runs with stdin enabled. By default pod has it disabled.
group: Workload Details
schema:
type: boolean
default: false
- variable: termination
group: Container Configuration
label: Termination settings
schema:
additional_attrs: true
type: dict
attrs:
- variable: gracePeriodSeconds
label: Grace Period Seconds
schema:
type: int
default: 10
- variable: podLabelsList
group: Container Configuration
label: Pod Labels
schema:
type: list
default: []
items:
- variable: podLabelItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string
- variable: podAnnotationsList
group: Container Configuration
label: Pod Annotations
schema:
type: list
default: []
items:
- variable: podAnnotationItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string

View File

@ -1,7 +0,0 @@
enum:
- value: deployment
description: Deployment
- value: statefulset
description: Statefulset
- value: daemonset
description: Daemonset

View File

@ -1,6 +1,6 @@
- variable: global - variable: global
label: Global Settings label: Global Settings
group: Controller group: "General Settings"
schema: schema:
type: dict type: dict
hidden: true hidden: true

View File

@ -1,10 +1,8 @@
groups: groups:
- name: Container Image - name: Container Image
description: Image to be used for container description: Image to be used for container
- name: Controller - name: General Settings
description: Configure Workload Deployment description: General Deployment Settings
- name: Container Configuration
description: Additional Container Configuration
- name: App Configuration - name: App Configuration
description: App Specific Config Options description: App Specific Config Options
- name: Networking and Services - name: Networking and Services
@ -21,6 +19,8 @@ groups:
description: Traefik Middlewares description: Traefik Middlewares
- name: Metrics - name: Metrics
description: Metrics description: Metrics
- name: VPN
description: VPN
- name: Addons - name: Addons
description: Addon Configuration description: Addon Configuration
- name: Advanced - name: Advanced

View File

@ -1,58 +1,53 @@
- variable: resources
- variable: advancedresources
label: Set Custom Resource Limits/Requests (Advanced)
group: Resources and Devices group: Resources and Devices
label: "Resource Limits"
schema: schema:
type: boolean additional_attrs: true
default: false type: dict
show_subquestions_if: true attrs:
subquestions: - variable: limits
- variable: resources label: Advanced Limit Resource Consumption
label: ""
schema: schema:
additional_attrs: true additional_attrs: true
type: dict type: dict
attrs: attrs:
- variable: limits - variable: cpu
label: Advanced Limit Resource Consumption label: CPU
description: "1000m means 1 hyperthread. Detailed info: https://truecharts.org/docs/manual/SCALE%20Apps/indepth/validation"
schema: schema:
additional_attrs: true type: string
type: dict default: 4000m
attrs: valid_chars: '^(?!^0(\.0|m|)$)([0-9]+)(\.[0-9]|m?)$'
- variable: cpu - variable: memory
label: CPU label: RAM
description: "1000m means 1 hyperthread. Detailed info: https://truecharts.org/docs/manual/SCALE%20Apps/indepth/validation" description: "1Gi means 1 Gibibyte RAM. Detailed info: https://truecharts.org/docs/manual/SCALE%20Apps/indepth/validation"
schema:
type: string
default: 4000m
valid_chars: '^(?!^0(\.0|m|)$)([0-9]+)(\.[0-9]|m?)$'
- variable: memory
label: RAM
description: "1Gi means 1 Gibibyte RAM. Detailed info: https://truecharts.org/docs/manual/SCALE%20Apps/indepth/validation"
schema:
type: string
default: 8Gi
valid_chars: '^(?!^0(e[0-9]|[EPTGMK]i?|)$)([0-9]+)(|[EPTGMK]i?|e[0-9]+)$'
- variable: requests
label: "Minimum Resources Required (request)"
schema: schema:
additional_attrs: true type: string
type: dict default: 8Gi
attrs: valid_chars: '^(?!^0(e[0-9]|[EPTGMK]i?|)$)([0-9]+)(|[EPTGMK]i?|e[0-9]+)$'
- variable: cpu - variable: requests
label: CPU label: "Minimum Resources Required (request)"
description: "1000m means 1 hyperthread. Detailed info: https://truecharts.org/docs/manual/SCALE%20Apps/indepth/validation" schema:
schema: additional_attrs: true
type: string type: dict
default: 10m hidden: true
valid_chars: '^(?!^0(\.0|m|)$)([0-9]+)(\.[0-9]|m?)$' attrs:
- variable: memory - variable: cpu
label: "RAM" label: CPU
description: "1Gi means 1 Gibibyte RAM. Detailed info: https://truecharts.org/docs/manual/SCALE%20Apps/indepth/validation" description: "1000m means 1 hyperthread. Detailed info: https://truecharts.org/docs/manual/SCALE%20Apps/indepth/validation"
schema: schema:
type: string type: string
default: 50Mi default: 10m
valid_chars: '^(?!^0(e[0-9]|[EPTGMK]i?|)$)([0-9]+)(|[EPTGMK]i?|e[0-9]+)$' hidden: true
valid_chars: '^(?!^0(\.0|m|)$)([0-9]+)(\.[0-9]|m?)$'
- variable: memory
label: "RAM"
description: "1Gi means 1 Gibibyte RAM. Detailed info: https://truecharts.org/docs/manual/SCALE%20Apps/indepth/validation"
schema:
type: string
default: 50Mi
hidden: true
valid_chars: '^(?!^0(e[0-9]|[EPTGMK]i?|)$)([0-9]+)(|[EPTGMK]i?|e[0-9]+)$'
- variable: deviceList - variable: deviceList
label: Mount USB Devices label: Mount USB Devices
group: Resources and Devices group: Resources and Devices

View File

@ -1,58 +0,0 @@
- variable: expert
label: Show Expert Configuration Options
schema:
type: boolean
default: false
show_subquestions_if: true
subquestions:
- variable: enableFixedMiddlewares
description: These middlewares enforce a number of best practices.
label: Enable Default Middlewares
schema:
type: boolean
default: true
- variable: ingressClassName
label: IngressClass Name
schema:
type: string
default: ""
- variable: labelsList
label: Labels
schema:
type: list
default: []
items:
- variable: labelItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string
- variable: annotationsList
label: Annotations
schema:
type: list
default: []
items:
- variable: annotationItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string

View File

@ -1,176 +0,0 @@
- variable: ingressList
label: Add Manual Custom Ingresses
group: Ingress
schema:
type: list
default: []
items:
- variable: ingressListEntry
label: Custom Ingress
schema:
additional_attrs: true
type: dict
attrs:
- variable: enabled
label: Enable Ingress
schema:
type: boolean
default: true
hidden: true
- variable: name
label: Name
schema:
type: string
default: ""
- variable: ingressClassName
label: IngressClass Name
schema:
type: string
default: ""
- variable: labelsList
label: Labels
schema:
type: list
default: []
items:
- variable: labelItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string
- variable: annotationsList
label: Annotations
schema:
type: list
default: []
items:
- variable: annotationItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string
- variable: hosts
label: Hosts
schema:
type: list
default: []
items:
- variable: hostEntry
label: Host
schema:
additional_attrs: true
type: dict
attrs:
- variable: host
label: HostName
schema:
type: string
default: ""
required: true
- variable: paths
label: Paths
schema:
type: list
default: []
items:
- variable: pathEntry
label: Host
schema:
additional_attrs: true
type: dict
attrs:
- variable: path
label: Path
schema:
type: string
required: true
default: "/"
- variable: pathType
label: Path Type
schema:
type: string
required: true
default: Prefix
- variable: service
label: Linked Service
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Service Name
schema:
type: string
default: ""
- variable: port
label: Service Port
schema:
type: int
- variable: tls
label: TLS-Settings
schema:
type: list
default: []
items:
- variable: tlsEntry
label: Host
schema:
additional_attrs: true
type: dict
attrs:
- variable: hosts
label: Certificate Hosts
schema:
type: list
default: []
items:
- variable: host
label: Host
schema:
type: string
default: ""
required: true
- variable: scaleCert
label: Select TrueNAS SCALE Certificate
schema:
type: int
$ref:
- "definitions/certificate"
- variable: entrypoint
label: Traefik Entrypoint
description: Entrypoint used by Traefik when using Traefik as Ingress Provider
schema:
type: string
default: websecure
required: true
- variable: middlewares
label: Traefik Middlewares
description: Add previously created Traefik Middlewares to this Ingress
schema:
type: list
default: []
items:
- variable: name
label: Name
schema:
type: string
default: ""
required: true

View File

@ -5,6 +5,11 @@
type: string type: string
default: websecure default: websecure
required: true required: true
- variable: ingressClassName
label: (Advanced/Optional) IngressClass Name
schema:
type: string
default: ""
- variable: middlewares - variable: middlewares
label: Traefik Middlewares label: Traefik Middlewares
description: Add previously created Traefik Middlewares to this Ingress description: Add previously created Traefik Middlewares to this Ingress

View File

@ -4,94 +4,3 @@
show_if: [["type", "=", "pvc"]] show_if: [["type", "=", "pvc"]]
type: string type: string
default: 256Gi default: 256Gi
- variable: hostPathType
label: (Advanced) hostPath Type
schema:
show_if: [["type", "=", "hostPath"]]
type: string
default: ""
enum:
- value: ""
description: Default
- value: DirectoryOrCreate
description: DirectoryOrCreate
- value: Directory
description: Directory
- value: FileOrCreate
description: FileOrCreate
- value: File
description: File
- value: Socket
description: Socket
- value: CharDevice
description: CharDevice
- value: BlockDevice
description: BlockDevice
- variable: storageClass
label: (Advanced) storageClass
description: "Warning: Anything other than SCALE-ZFS or empty will break rollback!"
schema:
show_if: [["type", "=", "pvc"]]
type: string
default: SCALE-ZFS
- variable: accessMode
label: (Advanced) Access Mode
description: Allow or disallow multiple PVC's writhing to the same PV
schema:
show_if: [["type", "=", "pvc"]]
type: string
default: ReadWriteOnce
enum:
- value: ReadWriteOnce
description: ReadWriteOnce
- value: ReadOnlyMany
description: ReadOnlyMany
- value: ReadWriteMany
description: ReadWriteMany
- variable: advanced
label: Show Advanced Options
schema:
type: boolean
default: false
show_subquestions_if: true
subquestions:
- variable: labelsList
label: Labels
schema:
type: list
default: []
items:
- variable: labelItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string
- variable: annotationsList
label: Annotations
schema:
type: list
default: []
items:
- variable: annotationItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string

View File

@ -3,18 +3,14 @@
description: Sets the persistence type, Anything other than PVC could break rollback! description: Sets the persistence type, Anything other than PVC could break rollback!
schema: schema:
type: string type: string
default: simplePVC default: pvc
enum: enum:
- value: simplePVC
description: PVC (simple)
- value: simpleHP
description: Host Path (simple)
- value: emptyDir
description: emptyDir
- value: pvc - value: pvc
description: PVC description: PVC
- value: hostPath - value: hostPath
description: Host Path description: Host Path
- value: emptyDir
description: emptyDir
- value: nfs - value: nfs
description: NFS Share description: NFS Share
- variable: server - variable: server
@ -29,13 +25,6 @@
show_if: [["type", "=", "nfs"]] show_if: [["type", "=", "nfs"]]
type: string type: string
default: "" default: ""
- variable: setPermissionsSimple
label: Automatic Permissions
description: Automatically set permissions on install
schema:
show_if: [["type", "=", "simpleHP"]]
type: boolean
default: false
- variable: setPermissions - variable: setPermissions
label: Automatic Permissions label: Automatic Permissions
description: Automatically set permissions on install description: Automatically set permissions on install
@ -48,12 +37,6 @@
schema: schema:
type: boolean type: boolean
default: false default: false
- variable: hostPathSimple
label: Host Path
description: Path inside the container the storage is mounted
schema:
show_if: [["type", "=", "simpleHP"]]
type: hostpath
- variable: hostPath - variable: hostPath
label: Host Path label: Host Path
description: Path inside the container the storage is mounted description: Path inside the container the storage is mounted
@ -71,3 +54,9 @@
description: Default description: Default
- value: Memory - value: Memory
description: Memory description: Memory
- variable: size
label: Size quotum of Storage
schema:
show_if: [["type", "=", "pvc"]]
type: string
default: 256Gi

View File

@ -27,18 +27,14 @@
description: Sets the persistence type, Anything other than PVC could break rollback! description: Sets the persistence type, Anything other than PVC could break rollback!
schema: schema:
type: string type: string
default: simpleHP default: hostPath
enum: enum:
- value: simplePVC
description: PVC (Simple)
- value: simpleHP
description: Host Path (Simple)
- value: emptyDir
description: emptyDir
- value: pvc - value: pvc
description: PVC description: PVC
- value: hostPath - value: hostPath
description: Host Path description: Host Path
- value: emptyDir
description: emptyDir
- value: nfs - value: nfs
description: NFS Share description: NFS Share
- variable: server - variable: server
@ -53,13 +49,6 @@
show_if: [["type", "=", "nfs"]] show_if: [["type", "=", "nfs"]]
type: string type: string
default: "" default: ""
- variable: setPermissionsSimple
label: Automatic Permissions
description: Automatically set permissions on install
schema:
show_if: [["type", "=", "simpleHP"]]
type: boolean
default: false
- variable: setPermissions - variable: setPermissions
label: Automatic Permissions label: Automatic Permissions
description: Automatically set permissions on install description: Automatically set permissions on install
@ -72,12 +61,6 @@
schema: schema:
type: boolean type: boolean
default: false default: false
- variable: hostPathSimple
label: Host Path
description: Path inside the container the storage is mounted
schema:
show_if: [["type", "=", "simpleHP"]]
type: hostpath
- variable: hostPath - variable: hostPath
label: Host Path label: Host Path
description: Path inside the container the storage is mounted description: Path inside the container the storage is mounted
@ -109,94 +92,3 @@
show_if: [["type", "=", "pvc"]] show_if: [["type", "=", "pvc"]]
type: string type: string
default: 256Gi default: 256Gi
- variable: hostPathType
label: (Advanced) Host Path Type
schema:
show_if: [["type", "=", "hostPath"]]
type: string
default: ""
enum:
- value: ""
description: Default
- value: DirectoryOrCreate
description: DirectoryOrCreate
- value: Directory
description: Directory
- value: FileOrCreate
description: FileOrCreate
- value: File
description: File
- value: Socket
description: Socket
- value: CharDevice
description: CharDevice
- value: BlockDevice
description: BlockDevice
- variable: storageClass
label: (Advanced) StorageClass
description: "Warning: Anything other than SCALE-ZFS or empty will break rollback!"
schema:
show_if: [["type", "=", "pvc"]]
type: string
default: SCALE-ZFS
- variable: accessMode
label: (Advanced) Access Mode
description: Allow or disallow multiple PVC's writhing to the same PV
schema:
show_if: [["type", "=", "pvc"]]
type: string
default: ReadWriteOnce
enum:
- value: ReadWriteOnce
description: ReadWriteOnce
- value: ReadOnlyMany
description: ReadOnlyMany
- value: ReadWriteMany
description: ReadWriteMany
- variable: advanced
label: Show Advanced Options
schema:
type: boolean
default: false
show_subquestions_if: true
subquestions:
- variable: labelsList
label: Labels
schema:
type: list
default: []
items:
- variable: labelItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string
- variable: annotationsList
label: Annotations
schema:
type: list
default: []
items:
- variable: annotationItem
label: Label
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string

View File

@ -1 +1 @@
default: 1 default: 1

View File

@ -1 +1 @@
default: 3 default: 3

View File

@ -1 +1 @@
default: 2 default: 2

View File

@ -1,6 +1,6 @@
- variable: replicas - variable: replicas
description: Number of desired pod replicas description: Number of desired pod replicas
label: Desired Replicas label: Desired Replicas
schema: schema:
type: int type: int
required: true required: true

View File

@ -1,26 +0,0 @@
- variable: capabilities
label: Capabilities
schema:
additional_attrs: true
type: dict
attrs:
- variable: drop
label: Drop Capability
schema:
type: list
default: []
items:
- variable: dropEntry
label: ""
schema:
type: string
- variable: add
label: Add Capability
schema:
type: list
default: []
items:
- variable: addEntry
label: ""
schema:
type: string

View File

@ -1,34 +1,14 @@
- variable: advanced - variable: protocol
label: Show Advanced Settings label: Port Type
schema: schema:
type: boolean type: string
default: false default: HTTPS
show_subquestions_if: true enum:
subquestions: - value: HTTP
- variable: enabled description: HTTP
label: Enable the Port - value: HTTPS
schema: description: HTTPS
type: boolean - value: TCP
hidden: true description: TCP
default: true - value: UDP
- variable: protocol description: UDP
label: Port Type
schema:
type: string
default: HTTPS
enum:
- value: HTTP
description: HTTP
- value: HTTPS
description: HTTPS
- value: TCP
description: TCP
- value: UDP
description: UDP
- variable: nodePort
label: Node Port (Optional)
description: This port gets exposed to the node. Only considered when service type is NodePort, Simple or LoadBalancer
schema:
type: int
min: 9000
max: 65535

View File

@ -1,34 +1,14 @@
- variable: advanced - variable: protocol
label: Show Advanced Settings label: Port Type
schema: schema:
type: boolean type: string
default: false default: TCP
show_subquestions_if: true enum:
subquestions: - value: HTTP
- variable: enabled description: HTTP
label: Enable the Port - value: HTTPS
schema: description: HTTPS
type: boolean - value: TCP
hidden: true description: TCP
default: true - value: UDP
- variable: protocol description: UDP
label: Port Type
schema:
type: string
default: TCP
enum:
- value: HTTP
description: HTTP
- value: HTTPS
description: HTTPS
- value: TCP
description: TCP
- value: UDP
description: UDP
- variable: nodePort
label: Node Port (Optional)
description: This port gets exposed to the node. Only considered when service type is NodePort, Simple or LoadBalancer
schema:
type: int
min: 9000
max: 65535

View File

@ -1,34 +1,14 @@
- variable: advanced - variable: protocol
label: Show Advanced Settings label: Port Type
schema: schema:
type: boolean type: string
default: false default: UDP
show_subquestions_if: true enum:
subquestions: - value: HTTP
- variable: enabled description: HTTP
label: Enable the Port - value: HTTPS
schema: description: HTTPS
type: boolean - value: TCP
hidden: true description: TCP
default: true - value: UDP
- variable: protocol description: UDP
label: Port Type
schema:
type: string
default: UDP
enum:
- value: HTTP
description: HTTP
- value: HTTPS
description: HTTPS
- value: TCP
description: TCP
- value: UDP
description: UDP
- variable: nodePort
label: Node Port (Optional)
description: This port gets exposed to the node. Only considered when service type is NodePort, Simple or LoadBalancer
schema:
type: int
min: 9000
max: 65535

View File

@ -74,64 +74,3 @@
type: ipaddr type: ipaddr
cidr: false cidr: false
required: true required: true
- variable: dnsPolicy
group: Networking and Services
label: dnsPolicy
schema:
type: string
default: ""
enum:
- value: ""
description: Default
- value: ClusterFirst
description: ClusterFirst
- value: None
description: None
- variable: dnsConfig
label: DNS Configuration
group: Networking and Services
description: Specify custom DNS configuration which will be applied to the pod
schema:
additional_attrs: true
type: dict
attrs:
- variable: nameservers
label: Name Servers
schema:
default: []
type: list
items:
- variable: nameserver
label: Name Server
schema:
type: string
- variable: options
label: Options
schema:
default: []
type: list
items:
- variable: option
label: Option Entry
schema:
additional_attrs: true
type: dict
attrs:
- variable: name
label: Name
schema:
type: string
- variable: value
label: Value
schema:
type: string
- variable: searches
label: Searches
schema:
default: []
type: list
items:
- variable: search
label: Search Entry
schema:
type: string

View File

@ -10,6 +10,7 @@
schema: schema:
type: boolean type: boolean
default: false default: false
hidden: true
show_subquestions_if: true show_subquestions_if: true
subquestions: subquestions:
- variable: externalIPs - variable: externalIPs
@ -17,6 +18,7 @@
description: "External IP's" description: "External IP's"
schema: schema:
type: list type: list
hidden: true
default: [] default: []
items: items:
- variable: externalIP - variable: externalIP
@ -29,6 +31,7 @@
schema: schema:
type: string type: string
default: SingleStack default: SingleStack
hidden: true
enum: enum:
- value: SingleStack - value: SingleStack
description: SingleStack description: SingleStack
@ -42,6 +45,7 @@
schema: schema:
type: list type: list
default: [] default: []
hidden: true
items: items:
- variable: ipFamily - variable: ipFamily
label: IP Family label: IP Family

View File

@ -1 +0,0 @@
default: Recreate

View File

@ -1 +0,0 @@
default: RollingUpdate

View File

@ -1,13 +0,0 @@
- variable: strategy
description: Please specify type of workload to deploy
label: (Advanced) Update Strategy
schema:
type: string
required: true
enum:
- value: Recreate
description: "Recreate: Kill existing pods before creating new ones"
- value: RollingUpdate
description: "RollingUpdate: Create new pods and then kill old ones"
- value: OnDelete
description: "(Legacy) OnDelete: ignore .spec.template changes"

View File

@ -78,11 +78,6 @@ chart_runner(){
train=$(basename $(dirname "${1}")) train=$(basename $(dirname "${1}"))
SCALESUPPORT=$(cat ${1}/Chart.yaml | yq '.annotations."truecharts.org/SCALE-support"' -r) SCALESUPPORT=$(cat ${1}/Chart.yaml | yq '.annotations."truecharts.org/SCALE-support"' -r)
helm dependency build "${1}" --skip-refresh || (sleep 10 && helm dependency build "${1}" --skip-refresh) || (sleep 10 && helm dependency build "${1}" --skip-refresh) helm dependency build "${1}" --skip-refresh || (sleep 10 && helm dependency build "${1}" --skip-refresh) || (sleep 10 && helm dependency build "${1}" --skip-refresh)
sync_tag "${1}" "${chartname}" "$train" "${chartversion}" || echo "Tag sync failed..."
# create_changelog "${1}" "${chartname}" "$train" "${chartversion}" || echo "changelog generation failed..."
# generate_docs "${1}" "${chartname}" "$train" "${chartversion}" || echo "Docs generation failed..."
#copy_docs "${1}" "${chartname}" "$train" "${chartversion}" || echo "Docs Copy failed..."
#package_chart "${1}"
if [[ "${SCALESUPPORT}" == "true" ]]; then if [[ "${SCALESUPPORT}" == "true" ]]; then
clean_apps "${1}" "${chartname}" "$train" "${chartversion}" clean_apps "${1}" "${chartname}" "$train" "${chartversion}"
copy_apps "${1}" "${chartname}" "$train" "${chartversion}" copy_apps "${1}" "${chartname}" "$train" "${chartversion}"
@ -133,61 +128,6 @@ clean_catalog() {
} }
export -f clean_catalog export -f clean_catalog
gen_dh_cat() {
rm -rf dh_catalog/*.*
rm -rf dh_catalog/*
cp -rf catalog/* dh_catalog
cd dh_catalog
find ./ -type f -name *.yaml -exec sed -i 's/tccr.io/dh.tccr.io/gI' {} \;
cd -
}
export -f gen_dh_cat
# Designed to ensure the appversion in Chart.yaml is in sync with the primary Chart tag if found
# Also makes sure that home link is pointing to the correct url
sync_tag() {
local chart="$1"
local chartname="$2"
local train="$3"
local chartversion="$4"
echo "Attempting to sync primary tag with appversion for: ${chartname}"
local tag="$(cat ${chart}/values.yaml | grep '^ tag: ' | awk -F" " '{ print $2 }' | head -1)"
tag="${tag%%@*}"
tag="${tag:-auto}"
tag=$(echo $tag | sed "s/release-//g")
tag=$(echo $tag | sed "s/release_//g")
tag=$(echo $tag | sed "s/version-//g")
tag=$(echo $tag | sed "s/version_//g")
tag="${tag#*V.}"
tag="${tag#*v-}"
tag="${tag#*v}"
tag="${tag%-*}"
tag="${tag:0:10}"
tag="${tag%-}"
tag="${tag%_}"
tag="${tag%.}"
echo "Updating tag of ${chartname} to ${tag}..."
sed -i -e "s|appVersion: .*|appVersion: \"${tag}\"|" "${chart}/Chart.yaml"
echo "Updating icon of ${chartname}..."
sed -i -e "s|icon: .*|icon: https:\/\/truecharts.org\/img\/hotlink-ok\/chart-icons\/${chartname}.png|" "${chart}/Chart.yaml"
echo "Updating home of ${chartname}..."
sed -i -e "s|home: .*|home: https:\/\/truecharts.org\/docs\/charts\/${train}\/${chartname}|" "${chart}/Chart.yaml"
echo "Attempting to update sources of ${chartname}..."
echo "Using go-yq verion: <$(go-yq -V)>"
# Get all sources (except truecharts)
curr_sources=$(go-yq '.sources[] | select(. != "https://github.com/truecharts*")' "${chart}/Chart.yaml")
# Empty sources list in-place
go-yq -i 'del(.sources.[])' "${chart}/Chart.yaml"
# Add truechart source
tcsource="https://github.com/truecharts/charts/tree/master/charts/$train/$chartname" go-yq -i '.sources += env(tcsource)' "${chart}/Chart.yaml"
# Add the rest of the sources
while IFS= read -r line; do
src="$line" go-yq -i '.sources += env(src)' "${chart}/Chart.yaml"
done <<< "$curr_sources"
echo "Sources of ${chartname} updated!"
}
export -f sync_tag
pre_commit() { pre_commit() {
if [[ -z "$standalone" ]]; then if [[ -z "$standalone" ]]; then
echo "Running pre-commit test-and-cleanup..." echo "Running pre-commit test-and-cleanup..."
@ -238,46 +178,6 @@ copy_general_docs() {
} }
export -f copy_general_docs export -f copy_general_docs
generate_docs() {
local chart="$1"
local chartname="$2"
local train="$3"
local chartversion="$4"
if [[ -z "$standalone" ]]; then
echo "Generating Docs"
if [ "${chartname}" == "common" ]; then
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="README.md" \
--template-files="/__w/apps/apps/templates/docs/common-README.md.gotmpl" \
--chart-search-root="${chart}"
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="helm-values.md" \
--template-files="/__w/apps/apps/templates/docs/common-helm-values.md.gotmpl" \
--chart-search-root="${chart}"
else
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="README.md" \
--template-files="/__w/apps/apps/templates/docs/README.md.gotmpl" \
--chart-search-root="${chart}"
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="CONFIG.md" \
--template-files="/__w/apps/apps/templates/docs/CONFIG.md.gotmpl" \
--chart-search-root="${chart}"
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="helm-values.md" \
--template-files="/__w/apps/apps/templates/docs/helm-values.md.gotmpl" \
--chart-search-root="${chart}"
fi
sed -i "s/TRAINPLACEHOLDER/${train}/" "${chart}/README.md"
fi
}
export -f generate_docs
copy_docs() { copy_docs() {
local chart="$1" local chart="$1"
@ -285,21 +185,14 @@ copy_docs() {
local train="$3" local train="$3"
local chartversion="$4" local chartversion="$4"
echo "Copying docs for: ${chart}" echo "Copying docs for: ${chart}"
if [ "${chartname}" == "common" ]; then mkdir -p docs/charts/${train}/${chartname} || echo "chart path already exists, continuing..."
mkdir -p docs/charts/common || : yes | cp -rf ${chart}/CHANGELOG.md docs/charts/${train}/${chartname}/CHANGELOG.md 2>/dev/null || :
yes | cp -rf charts/library/common/README.md docs/charts/common/index.md 2>/dev/null || : yes | cp -rf ${chart}/security.md docs/charts/${train}/${chartname}/security.md 2>/dev/null || :
yes | cp -rf charts/library/common/helm-values.md docs/charts/common/helm-values.md 2>/dev/null || : yes | cp -rf ${chart}/CONFIG.md docs/charts/${train}/${chartname}/CONFIG.md 2>/dev/null || :
else yes | cp -rf ${chart}/helm-values.md docs/charts/${train}/${chartname}/helm-values.md 2>/dev/null || :
mkdir -p docs/charts/${train}/${chartname} || echo "chart path already exists, continuing..." rm docs/charts/${train}/${chartname}/LICENSE.md 2>/dev/null || :
yes | cp -rf ${chart}/README.md docs/charts/${train}/${chartname}/index.md 2>/dev/null || : yes | cp -rf ${chart}/LICENSE docs/charts/${train}/${chartname}/LICENSE.md 2>/dev/null || :
yes | cp -rf ${chart}/CHANGELOG.md docs/charts/${train}/${chartname}/CHANGELOG.md 2>/dev/null || : sed -i '1s/^/# License<br>\n\n/' docs/charts/${train}/${chartname}/LICENSE.md 2>/dev/null || :
yes | cp -rf ${chart}/security.md docs/charts/${train}/${chartname}/security.md 2>/dev/null || :
yes | cp -rf ${chart}/CONFIG.md docs/charts/${train}/${chartname}/CONFIG.md 2>/dev/null || :
yes | cp -rf ${chart}/helm-values.md docs/charts/${train}/${chartname}/helm-values.md 2>/dev/null || :
rm docs/charts/${train}/${chartname}/LICENSE.md 2>/dev/null || :
yes | cp -rf ${chart}/LICENSE docs/charts/${train}/${chartname}/LICENSE.md 2>/dev/null || :
sed -i '1s/^/# License<br>\n\n/' docs/charts/${train}/${chartname}/LICENSE.md 2>/dev/null || :
fi
} }
export -f copy_docs export -f copy_docs
@ -308,8 +201,7 @@ prep_helm() {
helm repo add truecharts https://charts.truecharts.org helm repo add truecharts https://charts.truecharts.org
helm repo add truecharts-library https://library-charts.truecharts.org helm repo add truecharts-library https://library-charts.truecharts.org
helm repo add bitnami https://charts.bitnami.com/bitnami helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add metallb https://metallb.github.io/metallb
helm repo add grafana https://grafana.github.io/helm-charts
helm repo add prometheus https://prometheus-community.github.io/helm-charts helm repo add prometheus https://prometheus-community.github.io/helm-charts
helm repo update helm repo update
fi fi
@ -388,21 +280,6 @@ upload_catalog() {
} }
export -f upload_catalog export -f upload_catalog
upload_dhcatalog() {
echo "Uploading DH-Catalog..."
cd dh_catalog
git config user.name "TrueCharts-Bot"
git config user.email "bot@truecharts.org"
git add --all
git commit -sm "Commit new Chart releases for TrueCharts" || exit 0
git push
cd -
rm -rf dh_catalog
}
export -f upload_dhcatalog
parse_command_line() { parse_command_line() {
while :; do while :; do
case "${1:-}" in case "${1:-}" in
@ -533,56 +410,4 @@ lookup_changed_charts() {
} }
export -f lookup_changed_charts export -f lookup_changed_charts
package_chart() {
local chart="$1"
local args=("$chart" --package-path .cr-release-packages)
if [[ -n "$config" ]]; then
args+=(--config "$config")
fi
if [[ -z "$standalone" ]]; then
echo "Packaging chart '$chart'..."
cr package "${args[@]}"
fi
}
export -f package_chart
release_charts() {
local args=(-o "$owner" -r "$repo" -c "$(git rev-parse HEAD)")
if [[ -n "$config" ]]; then
args+=(--config "$config")
fi
if [[ -z "$standalone" ]]; then
echo 'Releasing charts...'
cr upload "${args[@]}"
fi
}
export -f release_charts
update_index() {
local args=(-o "$owner" -r "$repo" -c "$charts_repo_url")
if [[ -n "$config" ]]; then
args+=(--config "$config")
fi
if [[ -z "$standalone" ]]; then
echo 'Updating charts repo index...'
cr index "${args[@]}"
fi
}
export -f update_index
upload_index() {
cd .cr-index
git config user.name "TrueCharts-Bot"
git config user.email "bot@truecharts.org"
git add --all
git commit -sm "Commit released Helm Chart and docs for TrueCharts" || exit 0
git push
cd -
rm -rf .cr-index
}
export -f upload_index
main "$@" main "$@"