Compare commits
37 Commits
home-assis
...
node-red
Author | SHA1 | Date | |
---|---|---|---|
4dbcd74a03 | |||
a9da674caa | |||
bde3115c9c | |||
|
6472903b4f | ||
4f092eaa2a | |||
|
5fd7675ffb | ||
|
c5d44ffffa | ||
2180602e3a | |||
|
583643bcab | ||
|
e0864adab0 | ||
|
6cd276eaa3 | ||
|
0a72a599f7 | ||
|
5523cd61d1 | ||
|
c6c13e201b | ||
|
ba29643c98 | ||
|
7049e3fc4f | ||
|
9b04821db0 | ||
|
851c54d3cc | ||
|
e103640693 | ||
|
852a8e403e | ||
|
165fbc2946 | ||
|
2b33691e67 | ||
|
c31521018f | ||
|
911f56284f | ||
|
f08bcc331d | ||
|
13c879d1d5 | ||
|
6d3b50cf08 | ||
|
770044fba0 | ||
|
582f68d4f6 | ||
|
dd7146b905 | ||
|
a453aed4bd | ||
|
824964432c | ||
|
0165ead984 | ||
|
f5e44648a4 | ||
59cf68dea5 | |||
|
0d914ea479 | ||
39c0db5a0a |
58
.gitea/workflows/buildcharts.yaml
Normal file
58
.gitea/workflows/buildcharts.yaml
Normal file
@@ -0,0 +1,58 @@
|
|||||||
|
name: Package and publish helm chart
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
package-helm:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
name: Check out code
|
||||||
|
|
||||||
|
- name: Set up Helm
|
||||||
|
uses: azure/setup-helm@v4.2.0
|
||||||
|
with:
|
||||||
|
version: v3.14.4
|
||||||
|
|
||||||
|
- name: Set up yq
|
||||||
|
uses: mikefarah/yq@master
|
||||||
|
|
||||||
|
- name: Check for changed charts
|
||||||
|
id: changed-files
|
||||||
|
uses: tj-actions/changed-files@v44
|
||||||
|
with:
|
||||||
|
dir_names: true
|
||||||
|
dir_names_max_depth: '2'
|
||||||
|
files: 'charts/**'
|
||||||
|
|
||||||
|
- name: Run helm lint on all changed charts
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
ALL_CHANGED_CHARTS: ${{ steps.changed-files.outputs.all_changed_files }}
|
||||||
|
run: |
|
||||||
|
REPO_PATH=$(git rev-parse --show-toplevel)
|
||||||
|
for chart in ${ALL_CHANGED_CHARTS}; do
|
||||||
|
cd ${REPO_PATH}/${chart}
|
||||||
|
helm dependency build
|
||||||
|
helm lint .
|
||||||
|
done
|
||||||
|
|
||||||
|
- name: build helm package
|
||||||
|
shell: bash
|
||||||
|
if: gitea.ref == 'refs/heads/main'
|
||||||
|
env:
|
||||||
|
PACKAGE_TOKEN: ${{ secrets.PACKAGE_TOKEN }}
|
||||||
|
CHART_NAME: ${{ steps.chart_name.outputs.result }}
|
||||||
|
CHART_VERSION: ${{ steps.chart_version.outputs.result }}
|
||||||
|
ALL_CHANGED_CHARTS: ${{ steps.changed-files.outputs.all_changed_files }}
|
||||||
|
run: |
|
||||||
|
REPO_PATH=$(git rev-parse --show-toplevel)
|
||||||
|
for chart in ${ALL_CHANGED_CHARTS}; do
|
||||||
|
cd ${REPO_PATH}/${chart}
|
||||||
|
CHART_NAME=$(yq .name Chart.yaml)
|
||||||
|
CHART_VERSION=$(yq .version Chart.yaml)
|
||||||
|
echo "Packaging ${CHART_NAME}-${CHART_VERSION}"
|
||||||
|
helm package .
|
||||||
|
curl -H "Authorization: token $PACKAGE_TOKEN" -X POST --upload-file ${CHART_NAME}-${CHART_VERSION}.tgz https://git.rre.nu/api/packages/jonas/helm/api/charts
|
||||||
|
done
|
@@ -0,0 +1,6 @@
|
|||||||
|
# My helm-charts
|
||||||
|
|
||||||
|
Create a new chart with script:
|
||||||
|
```
|
||||||
|
scripts/new-chart <chart-name>
|
||||||
|
```
|
||||||
|
@@ -13,6 +13,19 @@ The following table lists the configurable parameters of the Home-assistant char
|
|||||||
| ------------------------ | ----------------------- | -------------- |
|
| ------------------------ | ----------------------- | -------------- |
|
||||||
| `image.repository` | | `"ghcr.io/home-assistant/home-assistant"` |
|
| `image.repository` | | `"ghcr.io/home-assistant/home-assistant"` |
|
||||||
| `image.tag` | | `null` |
|
| `image.tag` | | `null` |
|
||||||
|
| `controller.enabled` | should the main workload be included or not | `true` |
|
||||||
|
| `controller.type` | valid options are deployment, statefulset, job | `"statefulset"` |
|
||||||
|
| `service.http.enabled` | | `true` |
|
||||||
|
| `service.http.ports.http.port` | | `80` |
|
||||||
|
| `service.http.ports.http.targetPort` | | `8123` |
|
||||||
|
| `ingress.enabled` | | `false` |
|
||||||
|
| `ingress.service` | what service should the ingress target | `"http"` |
|
||||||
|
| `ingress.servicePort` | | `80` |
|
||||||
|
| `ingress.className` | | `"nginx"` |
|
||||||
|
| `ingress.hosts` | | `[{"host": "example.local", "paths": [{"path": "/", "pathType": "Prefix"}]}]` |
|
||||||
|
| `ingress.annotations` | | `{}` |
|
||||||
|
| `ingress.tls` | | `[]` |
|
||||||
|
| `volumeClaimTemplates` | | `[{"name": "config", "mountPath": "/config", "accessMode": "ReadWriteOnce", "storageClassName": "default", "size": "1Gi"}]` |
|
||||||
| `livenessProbe.httpGet.path` | | `"/"` |
|
| `livenessProbe.httpGet.path` | | `"/"` |
|
||||||
| `livenessProbe.httpGet.port` | | `8123` |
|
| `livenessProbe.httpGet.port` | | `8123` |
|
||||||
| `livenessProbe.initialDelaySeconds` | | `5` |
|
| `livenessProbe.initialDelaySeconds` | | `5` |
|
||||||
|
@@ -1,3 +1,4 @@
|
|||||||
|
|
||||||
image:
|
image:
|
||||||
repository: ghcr.io/home-assistant/home-assistant
|
repository: ghcr.io/home-assistant/home-assistant
|
||||||
tag:
|
tag:
|
||||||
|
18
charts/node-red/Chart.yaml
Normal file
18
charts/node-red/Chart.yaml
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v2
|
||||||
|
name: node-red
|
||||||
|
description:
|
||||||
|
type: application
|
||||||
|
version: 1.0.0
|
||||||
|
appVersion:
|
||||||
|
kubeVersion: ">=1.27.0"
|
||||||
|
home:
|
||||||
|
sources:
|
||||||
|
- https://git.rre.nu/jonas/helm-charts
|
||||||
|
maintainers:
|
||||||
|
- name: Jonas Forsberg
|
||||||
|
email: barregargamel@gmail.com
|
||||||
|
dependencies:
|
||||||
|
- name: lib
|
||||||
|
repository: https://git.rre.nu/api/packages/jonas/helm
|
||||||
|
version: 1.0.3
|
2
charts/node-red/Makefile
Normal file
2
charts/node-red/Makefile
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
doc:
|
||||||
|
frigate gen --output-format markdown --no-deps --no-credits ./ > README.md
|
1
charts/node-red/templates/base.tpl
Normal file
1
charts/node-red/templates/base.tpl
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{{ include "lib.all" . }}
|
32
charts/node-red/values.yaml
Normal file
32
charts/node-red/values.yaml
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
image:
|
||||||
|
repository:
|
||||||
|
tag:
|
||||||
|
|
||||||
|
controller: # main workload
|
||||||
|
enabled: true # should the main workload be included or not
|
||||||
|
type: deployment # valid options are deployment, statefulset, job
|
||||||
|
|
||||||
|
service:
|
||||||
|
http:
|
||||||
|
enabled: false
|
||||||
|
ports:
|
||||||
|
http:
|
||||||
|
port: 80
|
||||||
|
targetPort: 8123
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: false
|
||||||
|
service: http # what service should the ingress target
|
||||||
|
servicePort: 80
|
||||||
|
className: "nginx"
|
||||||
|
hosts:
|
||||||
|
- host: example.local
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
annotations:
|
||||||
|
{}
|
||||||
|
tls: []
|
||||||
|
# - secretName: chart-example-tls
|
||||||
|
# hosts:
|
||||||
|
# - chart-example.local
|
27
scripts/new-chart
Executable file
27
scripts/new-chart
Executable file
@@ -0,0 +1,27 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
if [[ "$(git rev-parse --abbrev-ref HEAD)" == "main" ]]; then
|
||||||
|
echo "Create a new branch first!"
|
||||||
|
exit 1;
|
||||||
|
fi
|
||||||
|
CHART_NAME="$1"
|
||||||
|
REPO_PATH=$(git rev-parse --show-toplevel)
|
||||||
|
|
||||||
|
type yq >/dev/null 2>&1 || { echo "yq not found, quitting!"; exit 1; }
|
||||||
|
|
||||||
|
if [[ -z "$CHART_NAME" ]]; then
|
||||||
|
echo "no chartname given"
|
||||||
|
exit 1;
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ -d "${REPO_PATH}/charts/${CHART_NAME}" ]]; then
|
||||||
|
echo "chart-name already exists"
|
||||||
|
exit 1;
|
||||||
|
fi
|
||||||
|
|
||||||
|
cp -r "${REPO_PATH}/skeleton" "${REPO_PATH}/charts/${CHART_NAME}"
|
||||||
|
|
||||||
|
yq -i ".name=\"${CHART_NAME}\"" "${REPO_PATH}/charts/${CHART_NAME}/Chart.yaml"
|
||||||
|
yq -i ".maintainers[0].name=\"$(git config user.name)\"" "${REPO_PATH}/charts/${CHART_NAME}/Chart.yaml"
|
||||||
|
yq -i ".maintainers[0].email=\"$(git config user.email)\"" "${REPO_PATH}/charts/${CHART_NAME}/Chart.yaml"
|
||||||
|
|
||||||
|
echo "Start editing your chart at: ${REPO_PATH}/charts/${CHART_NAME}/"
|
18
skeleton/Chart.yaml
Normal file
18
skeleton/Chart.yaml
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v2
|
||||||
|
name:
|
||||||
|
description:
|
||||||
|
type: application
|
||||||
|
version: 1.0.0
|
||||||
|
appVersion:
|
||||||
|
kubeVersion: ">=1.27.0"
|
||||||
|
home:
|
||||||
|
sources:
|
||||||
|
- https://git.rre.nu/jonas/helm-charts
|
||||||
|
maintainers:
|
||||||
|
- name:
|
||||||
|
email:
|
||||||
|
dependencies:
|
||||||
|
- name: lib
|
||||||
|
repository: https://git.rre.nu/api/packages/jonas/helm
|
||||||
|
version: 1.0.3
|
2
skeleton/Makefile
Normal file
2
skeleton/Makefile
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
doc:
|
||||||
|
frigate gen --output-format markdown --no-deps --no-credits ./ > README.md
|
1
skeleton/templates/base.tpl
Normal file
1
skeleton/templates/base.tpl
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{{ include "lib.all" . }}
|
32
skeleton/values.yaml
Normal file
32
skeleton/values.yaml
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
image:
|
||||||
|
repository:
|
||||||
|
tag:
|
||||||
|
|
||||||
|
controller: # main workload
|
||||||
|
enabled: true # should the main workload be included or not
|
||||||
|
type: deployment # valid options are deployment, statefulset, job
|
||||||
|
|
||||||
|
service:
|
||||||
|
http:
|
||||||
|
enabled: false
|
||||||
|
ports:
|
||||||
|
http:
|
||||||
|
port: 80
|
||||||
|
targetPort: 8123
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: false
|
||||||
|
service: http # what service should the ingress target
|
||||||
|
servicePort: 80
|
||||||
|
className: "nginx"
|
||||||
|
hosts:
|
||||||
|
- host: example.local
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
annotations:
|
||||||
|
{}
|
||||||
|
tls: []
|
||||||
|
# - secretName: chart-example-tls
|
||||||
|
# hosts:
|
||||||
|
# - chart-example.local
|
Reference in New Issue
Block a user