Add default values.yaml documentation and remove version from docs to prevent version bloat

This commit is contained in:
kjeld Schouten-Lebbing
2021-08-31 11:07:48 +02:00
parent fb82b853cb
commit b6bfd838da
4 changed files with 32 additions and 35 deletions
+8 -32
View File
@@ -65,10 +65,6 @@ jobs:
fi fi
done done
- name: run pre-commit checks
continue-on-error: true
uses: pre-commit/action@v2.0.3
- name: update versions in docs - name: update versions in docs
run: | run: |
for train in stable incubator; do for train in stable incubator; do
@@ -92,6 +88,11 @@ jobs:
--output-file="app-readme.md" \ --output-file="app-readme.md" \
--template-files="/home/runner/work/apps/apps/templates/docs/app-readme.md.gotmpl" \ --template-files="/home/runner/work/apps/apps/templates/docs/app-readme.md.gotmpl" \
--chart-search-root="${chart}" --chart-search-root="${chart}"
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="helm-values.md" \
--template-files="/home/runner/work/apps/apps/templates/docs/helm-values.md.gotmpl" \
--chart-search-root="${chart}"
fi fi
done done
done done
@@ -133,37 +134,11 @@ jobs:
pybump bump --file ./charts/${train}/${chart}/Chart.yaml --level patch pybump bump --file ./charts/${train}/${chart}/Chart.yaml --level patch
done done
- name: update versions in docs - name: run pre-commit checks
run: |
for train in stable incubator; do
for chart in charts/${train}/*; do
if [ -d "${chart}" ]; then
maxchartversion=$(cat ${chart}/Chart.yaml | grep "^version: " | awk -F" " '{ print $2 }')
chartname=$(basename ${chart})
echo "Copying templates to ${chart}"
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="README.md" \
--template-files="/home/runner/work/apps/apps/templates/docs/README.md.gotmpl" \
--chart-search-root="${chart}"
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="CONFIG.md" \
--template-files="/home/runner/work/apps/apps/templates/docs/CONFIG.md.gotmpl" \
--chart-search-root="${chart}"
helm-docs \
--ignore-file=".helmdocsignore" \
--output-file="app-readme.md" \
--template-files="/home/runner/work/apps/apps/templates/docs/app-readme.md.gotmpl" \
--chart-search-root="${chart}"
fi
done
done
- name: rerun pre-commit checks
continue-on-error: true continue-on-error: true
uses: pre-commit/action@v2.0.3 uses: pre-commit/action@v2.0.3
- name: Copy general readme to website - name: Copy general readme to website
run: | run: |
yes | cp -rf index.yaml docs/index.yaml || echo "chart-index copy failed, continuing..." yes | cp -rf index.yaml docs/index.yaml || echo "chart-index copy failed, continuing..."
@@ -189,6 +164,7 @@ jobs:
mkdir -p docs/apps/${train}/${chartname} || echo "app path already exists, continuing..." mkdir -p docs/apps/${train}/${chartname} || echo "app path already exists, continuing..."
yes | cp -rf ${chart}/README.md docs/apps/${train}/${chartname}/index.md || echo "readme copy failed, continuing..." yes | cp -rf ${chart}/README.md docs/apps/${train}/${chartname}/index.md || echo "readme copy failed, continuing..."
yes | cp -rf ${chart}/CONFIG.md docs/apps/${train}/${chartname}/CONFIG.md || echo "config copy failed, continuing..." yes | cp -rf ${chart}/CONFIG.md docs/apps/${train}/${chartname}/CONFIG.md || echo "config copy failed, continuing..."
yes | cp -rf ${chart}/helm-values.md docs/apps/${train}/${chartname}/helm-values.md || echo "config copy failed, continuing..."
yes | cp -rf ${chart}/LICENSE docs/apps/${train}/${chartname}/LICENSE.md || echo "license copy failed, continuing..." yes | cp -rf ${chart}/LICENSE docs/apps/${train}/${chartname}/LICENSE.md || echo "license copy failed, continuing..."
sed -i '1s/^/# License<br>\n\n/' docs/apps/${train}/${chartname}/LICENSE.md || echo "license edit failed, continuing..." sed -i '1s/^/# License<br>\n\n/' docs/apps/${train}/${chartname}/LICENSE.md || echo "license edit failed, continuing..."
fi fi
+2
View File
@@ -13,3 +13,5 @@ https://truecharts.org/manual/Quick-Start%20Guides/14-linking-apps/
In the future this page is going to contain an automated list of options available in the installation/edit UI. In the future this page is going to contain an automated list of options available in the installation/edit UI.
{{- end -}} {{- end -}}
{{ template "custom.custom.configuration" . }} {{ template "custom.custom.configuration" . }}
{{ template "custom.copyright" . }}
-3
View File
@@ -44,15 +44,12 @@ To remove this App from TrueNAS SCALE check our [Quick-Start Guide](https://true
- See the [Wiki](https://truecharts.org) - See the [Wiki](https://truecharts.org)
- Check our [Discord](https://discord.gg/tVsPTHWTtr) - Check our [Discord](https://discord.gg/tVsPTHWTtr)
- Open a [issue](https://github.com/truecharts/apps/issues/new/choose) - Open a [issue](https://github.com/truecharts/apps/issues/new/choose)
- Ask a [question](https://github.com/truecharts/apps/discussions)
{{- end -}} {{- end -}}
{{- define "custom.copyright" -}} {{- define "custom.copyright" -}}
All Rights Reserved - The TrueCharts Project All Rights Reserved - The TrueCharts Project
{{- end -}} {{- end -}}
{{ template "custom.introheader" . }} {{ template "custom.introheader" . }}
{{ template "chart.versionBadge" . }}{{ template "chart.typeBadge" . }}{{ template "chart.appVersionBadge" . }}
{{ template "chart.description" . }} {{ template "chart.description" . }}
{{ template "chart.deprecationWarning" . }} {{ template "chart.deprecationWarning" . }}
+22
View File
@@ -0,0 +1,22 @@
{{- define "custom.helm.introheader" -}}
# Default Helm-Values
{{- end -}}
{{- define "custom.helm.notes" -}}
TrueCharts is primarily build to supply TrueNAS SCALE Apps.
However, we also supply all Apps as standard Helm-Charts. In this document we aim to document the default values in our values.yaml file.
Most of our Apps also consume our "common" Helm Chart.
If this is the case, this means that all values.yaml values are set to the common chart values.yaml by default. This values.yaml file will only contain values that deviate from the common chart.
You will, however, be able to use all values referenced in the common chart here, besides the values listed in this document.
{{- end -}}
{{- define "custom.helm.copyright" -}}
All Rights Reserved - The TrueCharts Project
{{- end -}}
{{ template "custom.helm.introheader" . }}
{{ template "custom.helm.notes" . }}
{{ template "chart.valuesSection" . }}
{{ template "custom.helm.copyright" . }}