Skip to content
This repository has been archived by the owner on Aug 22, 2022. It is now read-only.

[ddclient] new chart #167

Merged
merged 6 commits into from Nov 16, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
24 changes: 24 additions & 0 deletions charts/ddclient/.helmignore
@@ -0,0 +1,24 @@
# 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
20 changes: 20 additions & 0 deletions charts/ddclient/Chart.yaml
@@ -0,0 +1,20 @@
apiVersion: v2
appVersion: 3.9.1
description: Perl client used to update dynamic DNS entries for accounts on Dynamic DNS Network Service Providers
name: ddclient
version: 1.0.0
keywords:
- ddclient
- dns
home: https://github.com/ddclient/ddclient
icon: https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/ddclient-logo.png
sources:
- https://github.com/ddclient/ddclient
- https://hub.docker.com/r/linuxserver/ddclient
maintainers:
- name: billimek
email: jeff@billimek.com
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.5.1
4 changes: 4 additions & 0 deletions charts/ddclient/OWNERS
@@ -0,0 +1,4 @@
approvers:
- billimek
reviewers:
- billimek
59 changes: 59 additions & 0 deletions charts/ddclient/README.md
@@ -0,0 +1,59 @@
# ddclient

This is a helm chart for [ddclient](https://github.com/ddclient/ddclient).

## TL;DR;

```shell
$ helm repo add k8s-at-home https://k8s-at-home.com/charts/
$ helm install k8s-at-home/ddclient
```

## Installing the Chart

To install the chart with the release name `my-release`:

```console
helm install --name my-release k8s-at-home/ddclient
```

## Uninstalling the Chart

To uninstall/delete the `my-release` deployment:

```console
helm delete my-release --purge
```

The command removes all the Kubernetes components associated with the chart and deletes the release.

## Configuration
Read through the charts [values.yaml](https://github.com/k8s-at-home/charts/blob/master/charts/ddclient/values.yaml)
file. It has several commented out suggested values.
Additionally you can take a look at the common library [values.yaml](https://github.com/k8s-at-home/charts/blob/master/charts/common/values.yaml) for more (advanced) configuration options.

Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,
```console
helm install ddclient \
--set env.TZ="America/New_York" \
k8s-at-home/ddclient
```
Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the
chart. For example,
```console
helm install ddclient k8s-at-home/ddclient --values values.yaml
```

```yaml
image:
tag: ...
```

---
**NOTE**

If you get
```console
Error: rendered manifests contain a resource that already exists. Unable to continue with install: existing resource conflict: ...`
```
it may be because you uninstalled the chart with `skipuninstall` enabled, you need to manually delete the pvc or use `existingClaim`.
7 changes: 7 additions & 0 deletions charts/ddclient/ci/ct-values.yaml
@@ -0,0 +1,7 @@
service:
enabled: false
probes:
liveness:
enabled: false
readiness:
enabled: false
1 change: 1 addition & 0 deletions charts/ddclient/templates/NOTES.txt
@@ -0,0 +1 @@
{{- include "common.notes.defaultNotes" . -}}
31 changes: 31 additions & 0 deletions charts/ddclient/templates/common.yaml
@@ -0,0 +1,31 @@
{{/* Make sure all variables are set properly */}}
{{- include "common.values.setup" . }}

{{/* Append the configMap to the additionalVolumes */}}
{{- define "ddclient.configmap.volume" -}}
name: ddclient-settings
configMap:
name: {{ template "common.names.fullname" . }}-settings
{{- end -}}

{{- $volume := include "ddclient.configmap.volume" . | fromYaml -}}
{{- if $volume -}}
{{- $additionalVolumes := append .Values.additionalVolumes $volume }}
{{- $_ := set .Values "additionalVolumes" (deepCopy $additionalVolumes) -}}
{{- end -}}

{{/* Append the configMap volume to the additionalVolumeMounts */}}
{{- define "ddclient.configmap.volumeMount" -}}
name: ddclient-settings
mountPath: /defaults/ddclient.conf
subPath: ddclient.conf
{{- end -}}

{{- $volumeMount := include "ddclient.configmap.volumeMount" . | fromYaml -}}
{{- if $volumeMount -}}
{{- $additionalVolumeMounts := append .Values.additionalVolumeMounts $volumeMount }}
{{- $_ := set .Values "additionalVolumeMounts" (deepCopy $additionalVolumeMounts) -}}
{{- end -}}

{{/* Render the templates */}}
{{ include "common.all" . }}
9 changes: 9 additions & 0 deletions charts/ddclient/templates/configmap.yaml
@@ -0,0 +1,9 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ template "common.names.fullname" . }}-settings
labels:
{{- include "common.labels" . | nindent 4 }}
data:
ddclient.conf: |
{{ .Values.config | indent 4 }}
37 changes: 37 additions & 0 deletions charts/ddclient/values.yaml
@@ -0,0 +1,37 @@
# Default values for ddclient.

image:
repository: linuxserver/ddclient
pullPolicy: IfNotPresent
tag: version-v3.9.1

env: {}
# TZ:
# PUID:
# PGID:

service:
enabled: false

probes:
liveness:
enabled: false
readiness:
enabled: false

strategy:
type: Recreate

config: |
# This is the configuration for ddclient
# Inorder for it to function you need to set it up
# e.g. this is the config for Cloudflare
use=web
web=dynamicdns.park-your-domain.com/getip
protocol=cloudflare
ssl=yes
ttl=1
login=${CF_EMAIL}
password=${CF_GLOBAL_APIKEY}
zone=${DOMAIN}.${TLD}
${DOMAIN}.${TLD}