mirror of
https://github.com/k8s-at-home/charts.git
synced 2025-01-24 07:59:02 +00:00
[powerdns] flip default to postgres, fix postgres dependent chart (#78)
This commit is contained in:
parent
f2452edfb9
commit
dde8baec08
@ -2,7 +2,7 @@ apiVersion: v2
|
|||||||
appVersion: v4.3.0
|
appVersion: v4.3.0
|
||||||
description: PowerDNS is a DNS server, written in C++ and licensed under the GPL. It runs on most Unix derivatives. PowerDNS features a large number of different backends ranging from simple BIND style zonefiles to relational databases and load balancing/failover algorithms. A DNS recursor is provided as a separate program.
|
description: PowerDNS is a DNS server, written in C++ and licensed under the GPL. It runs on most Unix derivatives. PowerDNS features a large number of different backends ranging from simple BIND style zonefiles to relational databases and load balancing/failover algorithms. A DNS recursor is provided as a separate program.
|
||||||
name: powerdns
|
name: powerdns
|
||||||
version: 2.2.0
|
version: 2.3.0
|
||||||
home: https://www.powerdns.com/
|
home: https://www.powerdns.com/
|
||||||
sources:
|
sources:
|
||||||
- http://www.github.com/PowerDNS/
|
- http://www.github.com/PowerDNS/
|
||||||
@ -12,7 +12,7 @@ maintainers:
|
|||||||
email: ryan@ryanholt.net
|
email: ryan@ryanholt.net
|
||||||
dependencies:
|
dependencies:
|
||||||
- name: postgresql
|
- name: postgresql
|
||||||
version: 9.8.12
|
version: 10.1.0
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
condition: postgres.enabled
|
condition: postgres.enabled
|
||||||
- name: mariadb
|
- name: mariadb
|
||||||
|
@ -35,28 +35,25 @@ spec:
|
|||||||
- name: config
|
- name: config
|
||||||
mountPath: /etc/pdns/conf.d
|
mountPath: /etc/pdns/conf.d
|
||||||
env:
|
env:
|
||||||
{{- if .Values.postgres.enabled }}
|
{{- if .Values.postgresql.enabled }}
|
||||||
|
- name: AUTOCONF
|
||||||
|
value: postgres
|
||||||
- name: PGSQL_HOST
|
- name: PGSQL_HOST
|
||||||
valueFrom:
|
valueFrom:
|
||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: {{ include "powerdns.fullname" . }}
|
name: {{ include "powerdns.fullname" . }}
|
||||||
key: postgres_host
|
key: postgres_host
|
||||||
- name: PGSQL_PORT
|
- name: PGSQL_USER
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: {{ include "powerdns.fullname" . }}
|
|
||||||
key: postgres_port
|
|
||||||
- name: PGSQL_USERNAME
|
|
||||||
valueFrom:
|
valueFrom:
|
||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: {{ include "powerdns.fullname" . }}
|
name: {{ include "powerdns.fullname" . }}
|
||||||
key: postgres_username
|
key: postgres_username
|
||||||
- name: PGSQL_PASSWORD
|
- name: PGSQL_PASS
|
||||||
valueFrom:
|
valueFrom:
|
||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: {{ include "powerdns.fullname" . }}
|
name: {{ include "powerdns.fullname" . }}
|
||||||
key: postgres_password
|
key: postgres_password
|
||||||
- name: PGSQL_DATABASE
|
- name: PGSQL_DB
|
||||||
valueFrom:
|
valueFrom:
|
||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: {{ include "powerdns.fullname" . }}
|
name: {{ include "powerdns.fullname" . }}
|
||||||
@ -65,6 +62,8 @@ spec:
|
|||||||
value: {{if (.Values.powerdns.dnssec)}}"yes"{{else}}"no"{{ end }}
|
value: {{if (.Values.powerdns.dnssec)}}"yes"{{else}}"no"{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{- if .Values.mariadb.enabled }}
|
{{- if .Values.mariadb.enabled }}
|
||||||
|
- name: AUTOCONF
|
||||||
|
value: mysql
|
||||||
- name: MYSQL_HOST
|
- name: MYSQL_HOST
|
||||||
valueFrom:
|
valueFrom:
|
||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
@ -95,32 +94,26 @@ spec:
|
|||||||
- name: dns-udp
|
- name: dns-udp
|
||||||
containerPort: 53
|
containerPort: 53
|
||||||
protocol: UDP
|
protocol: UDP
|
||||||
- name: dns-webserver
|
|
||||||
containerPort: 8081
|
|
||||||
protocol: TCP
|
|
||||||
{{- if .Values.probes.liveness.enabled }}
|
{{- if .Values.probes.liveness.enabled }}
|
||||||
livenessProbe:
|
livenessProbe:
|
||||||
httpGet:
|
tcpSocket:
|
||||||
path: /
|
port: dns-tcp
|
||||||
port: dns-webserver
|
|
||||||
initialDelaySeconds: {{ .Values.probes.liveness.initialDelaySeconds }}
|
initialDelaySeconds: {{ .Values.probes.liveness.initialDelaySeconds }}
|
||||||
failureThreshold: {{ .Values.probes.liveness.failureThreshold }}
|
failureThreshold: {{ .Values.probes.liveness.failureThreshold }}
|
||||||
timeoutSeconds: {{ .Values.probes.liveness.timeoutSeconds }}
|
timeoutSeconds: {{ .Values.probes.liveness.timeoutSeconds }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{- if .Values.probes.readiness.enabled }}
|
{{- if .Values.probes.readiness.enabled }}
|
||||||
readinessProbe:
|
readinessProbe:
|
||||||
httpGet:
|
tcpSocket:
|
||||||
path: /
|
port: dns-tcp
|
||||||
port: dns-webserver
|
|
||||||
initialDelaySeconds: {{ .Values.probes.readiness.initialDelaySeconds }}
|
initialDelaySeconds: {{ .Values.probes.readiness.initialDelaySeconds }}
|
||||||
failureThreshold: {{ .Values.probes.readiness.failureThreshold }}
|
failureThreshold: {{ .Values.probes.readiness.failureThreshold }}
|
||||||
timeoutSeconds: {{ .Values.probes.readiness.timeoutSeconds }}
|
timeoutSeconds: {{ .Values.probes.readiness.timeoutSeconds }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{- if .Values.probes.startup.enabled }}
|
{{- if .Values.probes.startup.enabled }}
|
||||||
startupProbe:
|
startupProbe:
|
||||||
httpGet:
|
tcpSocket:
|
||||||
path: /
|
port: dns-tcp
|
||||||
port: dns-webserver
|
|
||||||
failureThreshold: {{ .Values.probes.startup.failureThreshold }}
|
failureThreshold: {{ .Values.probes.startup.failureThreshold }}
|
||||||
periodSeconds: {{ .Values.probes.startup.periodSeconds }}
|
periodSeconds: {{ .Values.probes.startup.periodSeconds }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
@ -128,13 +121,13 @@ spec:
|
|||||||
lifecycle:
|
lifecycle:
|
||||||
postStart:
|
postStart:
|
||||||
exec:
|
exec:
|
||||||
command: ["/bin/sh", "-c", "a=0;while [ $a -lt 200 ];do sleep 5;a=$[a+1];echo 'stage: '$a;if nc -vz {{ .Values.powerdns.mysql.host }} 3306;then (! pdnsutil list-zone {{ .Values.powerdns.domain }} 2>/dev/null) && pdnsutil create-zone {{ .Values.powerdns.domain }};echo 'End Stage';a=200;fi;done"]
|
command: ["/bin/sh", "-c", "a=0;while [ $a -lt 200 ];do sleep 5;a=$[a+1];echo 'stage: '$a;if nc -vz {{- printf "%s-%s" .Release.Name "mariadb"}} 3306;then (! pdnsutil list-zone {{ .Values.powerdns.domain }} 2>/dev/null) && pdnsutil create-zone {{ .Values.powerdns.domain }};echo 'End Stage';a=200;fi;done"]
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{- if .Values.postgres.enabled }}
|
{{- if .Values.postgresql.enabled }}
|
||||||
lifecycle:
|
lifecycle:
|
||||||
postStart:
|
postStart:
|
||||||
exec:
|
exec:
|
||||||
command: ["/bin/sh", "-c", "a=0;while [ $a -lt 200 ];do sleep 5;a=$[a+1];echo 'stage: '$a;if nc -vz {{ .Values.powerdns.postgres.host }} 5432;then (! pdnsutil list-zone {{ .Values.powerdns.domain }} 2>/dev/null) && pdnsutil create-zone {{ .Values.powerdns.domain }};echo 'End Stage';a=200;fi;done"]
|
command: ["/bin/sh", "-c", "a=0;while [ $a -lt 200 ];do sleep 5;a=$[a+1];echo 'stage: '$a;if nc -vz {{- printf "%s-%s" .Release.Name "postgresql"}} 5432;then (! pdnsutil list-zone {{ .Values.powerdns.domain }} 2>/dev/null) && pdnsutil create-zone {{ .Values.powerdns.domain }};echo 'End Stage';a=200;fi;done"]
|
||||||
{{ end }}
|
{{ end }}
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.resources | nindent 12 }}
|
{{- toYaml .Values.resources | nindent 12 }}
|
||||||
|
@ -6,13 +6,12 @@ metadata:
|
|||||||
{{ include "powerdns.labels" . | indent 4 }}
|
{{ include "powerdns.labels" . | indent 4 }}
|
||||||
type: Opaque
|
type: Opaque
|
||||||
data:
|
data:
|
||||||
{{- if .Values.postgres.enabled }}
|
{{- if .Values.postgresql.enabled }}
|
||||||
{{- $postgrestmp := printf "%s-%s" .Release.Name "postgres"}}
|
{{- $postgrestmp := printf "%s-%s" .Release.Name "postgresql"}}
|
||||||
postgres_host: "{{ $postgrestmp |b64enc }}"
|
postgres_host: "{{ $postgrestmp |b64enc }}"
|
||||||
postgres_port: "{{ .Values.powerdns.postgres.port | toString | b64enc }}"
|
postgres_username: "{{ .Values.postgresql.postgresqlUsername | b64enc }}"
|
||||||
postgres_username: "{{ .Values.powerdns.postgres.username | b64enc }}"
|
postgres_password: "{{ .Values.postgresql.postgresqlPassword | toString | b64enc }}"
|
||||||
postgres_password: "{{ .Values.powerdns.postgres.password | toString | b64enc }}"
|
postgres_database: "{{ .Values.postgresql.postgresqlDatabase | b64enc }}"
|
||||||
postgres_database: "{{ .Values.powerdns.postgres.database | b64enc }}"
|
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{- if .Values.mariadb.enabled }}
|
{{- if .Values.mariadb.enabled }}
|
||||||
{{- $mysqltmp := printf "%s-%s" .Release.Name "mariadb"}}
|
{{- $mysqltmp := printf "%s-%s" .Release.Name "mariadb"}}
|
||||||
|
@ -6,8 +6,8 @@ replicaCount: 1
|
|||||||
strategyType: Recreate
|
strategyType: Recreate
|
||||||
|
|
||||||
image:
|
image:
|
||||||
repository: psitrax/powerdns
|
repository: naps/powerdns
|
||||||
tag: v4.3.0
|
tag: 4.3.1
|
||||||
pullPolicy: Always
|
pullPolicy: Always
|
||||||
|
|
||||||
imagePullSecrets: []
|
imagePullSecrets: []
|
||||||
@ -71,8 +71,10 @@ powerdns:
|
|||||||
dnssec: true
|
dnssec: true
|
||||||
config: {}
|
config: {}
|
||||||
|
|
||||||
|
# Enabled mariadb
|
||||||
|
# ... for more options see https://github.com/bitnami/charts/tree/master/bitnami/mariadb
|
||||||
mariadb:
|
mariadb:
|
||||||
enabled: true
|
enabled: false
|
||||||
db:
|
db:
|
||||||
name: pdns
|
name: pdns
|
||||||
user: pdns
|
user: pdns
|
||||||
@ -84,12 +86,19 @@ mariadb:
|
|||||||
master:
|
master:
|
||||||
persistence:
|
persistence:
|
||||||
enabled: false
|
enabled: false
|
||||||
postgres:
|
|
||||||
enabled: false
|
# Enabled postgres
|
||||||
global:
|
# ... for more options see https://github.com/bitnami/charts/tree/master/bitnami/postgresql
|
||||||
|
postgresql:
|
||||||
|
enabled: true
|
||||||
postgresqlUsername: pdns
|
postgresqlUsername: pdns
|
||||||
postgresqlPassword: pdnspass
|
postgresqlPassword: pdnspass
|
||||||
|
postgresqlPostgresPassword: pdnsadminpass
|
||||||
postgresqlDatabase: pdns
|
postgresqlDatabase: pdns
|
||||||
|
persistence:
|
||||||
|
enabled: false
|
||||||
|
# storageClass: ""
|
||||||
|
|
||||||
|
|
||||||
# Probes configuration
|
# Probes configuration
|
||||||
probes:
|
probes:
|
||||||
|
Loading…
Reference in New Issue
Block a user