Skip to content
This repository was archived by the owner on Feb 22, 2022. It is now read-only.
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions stable/coredns/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: coredns
version: 0.4.0
description: CoreDNS is a DNS server that chains middleware and provides Kubernetes DNS Services
version: 0.5.0
description: CoreDNS is a DNS server that chains middleware and provides Kubernetes
DNS Services
keywords:
- coredns
- dns
Expand Down
8 changes: 4 additions & 4 deletions stable/coredns/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,22 @@ CoreDNS is now running in the cluster as a cluster-service.
CoreDNS is now running in the cluster.
It can be accessed using the below endpoint
{{- if contains "NodePort" .Values.serviceType }}
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "fullname" . }})
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "coredns.fullname" . }})
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
echo "$NODE_IP:$NODE_PORT"
{{- else if contains "LoadBalancer" .Values.serviceType }}
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
You can watch the status by running 'kubectl get svc -w {{ template "fullname" . }}'
You can watch the status by running 'kubectl get svc -w {{ template "coredns.fullname" . }}'

{{- if contains "UDPNTCP" .Values.serviceProtocol }}
NOTE: Some cloud environments cannot create external loadbalancers with both "TCP" and "UDP" protocols.
So in case of error, use either "UDP" or "TCP" protocol by setting `serviceProtocol` parameter.
{{- end }}

export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ template "fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ template "coredns.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
echo $SERVICE_IP
{{- else if contains "ClusterIP" .Values.serviceType }}
"{{ template "fullname" . }}.{{ .Release.Namespace }}.svc.cluster.local"
"{{ template "coredns.fullname" . }}.{{ .Release.Namespace }}.svc.cluster.local"
from within the cluster
{{- end }}
{{- end }}
Expand Down
4 changes: 2 additions & 2 deletions stable/coredns/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "name" -}}
{{- define "coredns.name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
{{- end -}}

{{/*
Create a default fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
*/}}
{{- define "fullname" -}}
{{- define "coredns.fullname" -}}
{{- $name := default .Chart.Name .Values.nameOverride -}}
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
{{- end -}}
2 changes: 1 addition & 1 deletion stable/coredns/templates/configmap.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ template "fullname" . }}
name: {{ template "coredns.fullname" . }}
data:
Corefile: |-
.:53 {
Expand Down
10 changes: 5 additions & 5 deletions stable/coredns/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: {{ template "fullname" . }}
name: {{ template "coredns.fullname" . }}
labels:
heritage: {{ .Release.Service | quote }}
release: {{ .Release.Name | quote }}
Expand All @@ -11,7 +11,7 @@ metadata:
kubernetes.io/cluster-service: "true"
kubernetes.io/name: "CoreDNS"
{{- else }}
app: {{ template "fullname" . }}
app: {{ template "coredns.fullname" . }}
{{- end }}
spec:
replicas: {{ .Values.replicaCount }}
Expand All @@ -20,15 +20,15 @@ spec:
{{- if .Values.isClusterService }}
k8s-app: {{ .Chart.Name | quote }}
{{- else }}
app: {{ template "fullname" . }}
app: {{ template "coredns.fullname" . }}
{{- end }}
template:
metadata:
labels:
{{- if .Values.isClusterService }}
k8s-app: {{ .Chart.Name | quote }}
{{- else }}
app: {{ template "fullname" . }}
app: {{ template "coredns.fullname" . }}
{{- end }}
release: {{ .Release.Name | quote }}
annotations:
Expand Down Expand Up @@ -78,7 +78,7 @@ spec:
volumes:
- name: config-volume
configMap:
name: {{ template "fullname" . }}
name: {{ template "coredns.fullname" . }}
items:
- key: Corefile
path: Corefile
6 changes: 3 additions & 3 deletions stable/coredns/templates/service.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v1
kind: Service
metadata:
name: {{ template "fullname" . }}
name: {{ template "coredns.fullname" . }}
labels:
heritage: {{ .Release.Service | quote }}
release: {{ .Release.Name | quote }}
Expand All @@ -11,7 +11,7 @@ metadata:
kubernetes.io/cluster-service: "true"
kubernetes.io/name: "CoreDNS"
{{- else }}
app: {{ template "fullname" . }}
app: {{ template "coredns.fullname" . }}
{{- end }}
annotations:
{{- if .Values.middleware.prometheus.enabled }}
Expand All @@ -23,7 +23,7 @@ spec:
{{- if .Values.isClusterService }}
k8s-app: {{ .Chart.Name | quote }}
{{- else }}
app: {{ template "fullname" . }}
app: {{ template "coredns.fullname" . }}
{{- end }}
{{- if .Values.isClusterService }}
clusterIP: {{ .Values.middleware.kubernetes.clusterIP }}
Expand Down