apiVersion: v1
kind: Pod
metadata:
  name: bootstrap-etcd
  namespace: kube-system
  labels:
    k8s-app: boot-etcd
spec:
  containers:
  - name: etcd
    image: ${etcd_image}
    command:
    - /usr/local/bin/etcd
    - --name=boot-etcd
    - --listen-client-urls=http://0.0.0.0:12379
    - --listen-peer-urls=http://0.0.0.0:12380
    - --advertise-client-urls=http://${bootstrap_etcd_service_ip}:12379
    - --initial-advertise-peer-urls=http://${bootstrap_etcd_service_ip}:12380
    - --initial-cluster=boot-etcd=http://${bootstrap_etcd_service_ip}:12380
    - --initial-cluster-token=bootkube
    - --initial-cluster-state=new
    - --data-dir=/var/etcd/data
  hostNetwork: true
  restartPolicy: Never
