[blocky] update blocky for v0.6 (#200)

* update blocky for v0.6

* fix missing port rename

* making service spec more robust

* make defaults sane
This commit is contained in:
Jeff Billimek 2020-04-14 09:31:23 -04:00 committed by GitHub
parent 9bef0aac5e
commit 6dd129e4a9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 48 additions and 12 deletions

View File

@ -1,8 +1,8 @@
apiVersion: v1 apiVersion: v1
appVersion: "v0.5" appVersion: "v0.6"
description: DNS proxy as ad-blocker for local network description: DNS proxy as ad-blocker for local network
name: blocky name: blocky
version: 2.2.2 version: 2.3.0
keywords: keywords:
- blocky - blocky
- dbs - dbs

View File

@ -40,7 +40,7 @@ spec:
readOnly: true readOnly: true
ports: ports:
ports: ports:
- name: monitoring - name: api
containerPort: 4000 containerPort: 4000
- name: dns - name: dns
containerPort: 53 containerPort: 53
@ -51,19 +51,19 @@ spec:
livenessProbe: livenessProbe:
httpGet: httpGet:
path: /metrics path: /metrics
port: monitoring port: api
failureThreshold: {{ .Values.probes.liveness.failureThreshold }} failureThreshold: {{ .Values.probes.liveness.failureThreshold }}
periodSeconds: {{ .Values.probes.liveness.periodSeconds }} periodSeconds: {{ .Values.probes.liveness.periodSeconds }}
readinessProbe: readinessProbe:
httpGet: httpGet:
path: /metrics path: /metrics
port: monitoring port: api
failureThreshold: {{ .Values.probes.readiness.failureThreshold }} failureThreshold: {{ .Values.probes.readiness.failureThreshold }}
periodSeconds: {{ .Values.probes.readiness.periodSeconds }} periodSeconds: {{ .Values.probes.readiness.periodSeconds }}
startupProbe: startupProbe:
httpGet: httpGet:
path: /metrics path: /metrics
port: monitoring port: api
initialDelaySeconds: {{ .Values.probes.startup.initialDelaySeconds }} initialDelaySeconds: {{ .Values.probes.startup.initialDelaySeconds }}
failureThreshold: {{ .Values.probes.startup.failureThreshold }} failureThreshold: {{ .Values.probes.startup.failureThreshold }}
periodSeconds: {{ .Values.probes.startup.periodSeconds }} periodSeconds: {{ .Values.probes.startup.periodSeconds }}

View File

@ -7,12 +7,39 @@ metadata:
helm.sh/chart: {{ include "blocky.chart" . }} helm.sh/chart: {{ include "blocky.chart" . }}
app.kubernetes.io/instance: {{ .Release.Name }} app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/managed-by: {{ .Release.Service }} app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- if .Values.service.annotations }}
annotations:
{{ toYaml .Values.service.annotations | indent 4 }}
{{- end }}
spec: spec:
clusterIP: None {{- if (or (eq .Values.service.type "ClusterIP") (empty .Values.service.type)) }}
type: ClusterIP
{{- if .Values.service.clusterIP }}
clusterIP: {{ .Values.service.clusterIP }}
{{end}}
{{- else if eq .Values.service.type "LoadBalancer" }}
type: {{ .Values.service.type }}
{{- if .Values.service.loadBalancerIP }}
loadBalancerIP: {{ .Values.service.loadBalancerIP }}
{{- end }}
{{- if .Values.service.loadBalancerSourceRanges }}
loadBalancerSourceRanges:
{{ toYaml .Values.service.loadBalancerSourceRanges | indent 4 }}
{{- end -}}
{{- else }}
type: {{ .Values.service.type }}
{{- end }}
{{- if .Values.service.externalIPs }}
externalIPs:
{{ toYaml .Values.service.externalIPs | indent 4 }}
{{- end }}
{{- if .Values.service.externalTrafficPolicy }}
externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy }}
{{- end }}
ports: ports:
- name: monitoring - name: api
port: 4000 port: 4000
targetPort: monitoring targetPort: api
selector: selector:
app.kubernetes.io/name: {{ include "blocky.name" . }} app.kubernetes.io/name: {{ include "blocky.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }} app.kubernetes.io/instance: {{ .Release.Name }}

View File

@ -17,7 +17,7 @@ spec:
app.kubernetes.io/name: {{ include "blocky.name" . }} app.kubernetes.io/name: {{ include "blocky.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }} app.kubernetes.io/instance: {{ .Release.Name }}
endpoints: endpoints:
- port: monitoring - port: api
interval: 30s interval: 30s
path: /metrics path: /metrics
{{- end }} {{- end }}

View File

@ -2,7 +2,7 @@ replicaCount: 1
image: image:
repository: spx01/blocky repository: spx01/blocky
tag: v0.5 tag: v0.6
pullPolicy: IfNotPresent pullPolicy: IfNotPresent
nameOverride: "" nameOverride: ""
@ -119,6 +119,15 @@ probes:
failureThreshold: 30 failureThreshold: 30
periodSeconds: 10 periodSeconds: 10
service:
type: ClusterIP
# externalTrafficPolicy: Local
# loadBalancerIP: ""
# a fixed LoadBalancer IP
annotations: {}
# metallb.universe.tf/address-pool: network-services
# metallb.universe.tf/allow-shared-ip: blocky-svc
serviceTCP: serviceTCP:
enabled: false enabled: false
type: NodePort type: NodePort
@ -146,7 +155,7 @@ serviceMonitor:
## Pod Annotations ## Pod Annotations
podAnnotations: podAnnotations:
prometheus.io/scrape: "true" prometheus.io/scrape: "true"
prometheus.io/port: "monitoring" prometheus.io/port: "api"
resources: {} resources: {}
# We usually recommend not to specify default resources and to leave this as a conscious # We usually recommend not to specify default resources and to leave this as a conscious