Skip to content

Instantly share code, notes, and snippets.

@rbramwell
Forked from mauilion/etcdclient.yaml
Created December 3, 2020 12:37
Show Gist options
  • Save rbramwell/5651a33a70f69ee13299a61a8906f03d to your computer and use it in GitHub Desktop.
Save rbramwell/5651a33a70f69ee13299a61a8906f03d to your computer and use it in GitHub Desktop.
etcdclient static pod with all the bits configured.
apiVersion: v1
kind: Pod
metadata:
creationTimestamp: null
labels:
component: etcdclient
tier: debug
name: etcdclient
namespace: kube-system
spec:
containers:
- command:
- sleep
- 9999d
image: k8s.gcr.io/etcd:3.3.10
imagePullPolicy: IfNotPresent
name: etcdclient
resources: {}
volumeMounts:
- mountPath: /etc/kubernetes/pki/etcd
name: etcd-certs
readOnly: true
- mountPath: /var/lib/etcd
name: etcd-data
readOnly: false
env:
- name: ETCDCTL_API
value: "3"
- name: ETCDCTL_CACERT
value: /etc/kubernetes/pki/etcd/ca.crt
- name: ETCDCTL_CERT
value: /etc/kubernetes/pki/etcd/healthcheck-client.crt
- name: ETCDCTL_KEY
value: /etc/kubernetes/pki/etcd/healthcheck-client.key
- name: ETCDCTL_ENDPOINTS
value: "https://127.0.0.1:2379"
- name: ETCDCTL_CLUSTER
value: "true"
hostNetwork: true
volumes:
- hostPath:
path: /etc/kubernetes/pki/etcd
type: DirectoryOrCreate
name: etcd-certs
- hostPath:
path: /var/lib/etcd
type: DirectoryOrCreate
name: etcd-data
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment