123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189 |
- apiVersion: v1
- kind: Service
- metadata:
- name: etcd-client
- spec:
- ports:
- - name: etcd-client-port
- port: 2379
- protocol: TCP
- targetPort: 2379
- selector:
- app: etcd
- ---
- apiVersion: v1
- kind: Pod
- metadata:
- labels:
- app: etcd
- etcd_node: etcd0
- name: etcd0
- spec:
- containers:
- - command:
- - /etcd
- - --name
- - etcd0
- - --initial-advertise-peer-urls
- - http://etcd0:2380
- - --listen-peer-urls
- - http://0.0.0.0:2380
- - --listen-client-urls
- - http://0.0.0.0:2379
- - --advertise-client-urls
- - http://etcd0:2379
- - --initial-cluster
- - etcd0=http://etcd0:2380,etcd1=http://etcd1:2380,etcd2=http://etcd2:2380
- - --initial-cluster-state
- - new
- image: quay.io/coreos/etcd:latest
- name: etcd0
- ports:
- - containerPort: 2379
- name: client
- protocol: TCP
- - containerPort: 2380
- name: server
- protocol: TCP
- restartPolicy: Never
- ---
- apiVersion: v1
- kind: Service
- metadata:
- labels:
- etcd_node: etcd0
- name: etcd0
- spec:
- ports:
- - name: client
- port: 2379
- protocol: TCP
- targetPort: 2379
- - name: server
- port: 2380
- protocol: TCP
- targetPort: 2380
- selector:
- etcd_node: etcd0
- ---
- apiVersion: v1
- kind: Pod
- metadata:
- labels:
- app: etcd
- etcd_node: etcd1
- name: etcd1
- spec:
- containers:
- - command:
- - /etcd
- - --name
- - etcd1
- - --initial-advertise-peer-urls
- - http://etcd1:2380
- - --listen-peer-urls
- - http://0.0.0.0:2380
- - --listen-client-urls
- - http://0.0.0.0:2379
- - --advertise-client-urls
- - http://etcd1:2379
- - --initial-cluster
- - etcd0=http://etcd0:2380,etcd1=http://etcd1:2380,etcd2=http://etcd2:2380
- - --initial-cluster-state
- - new
- image: quay.io/coreos/etcd:latest
- name: etcd1
- ports:
- - containerPort: 2379
- name: client
- protocol: TCP
- - containerPort: 2380
- name: server
- protocol: TCP
- restartPolicy: Never
- ---
- apiVersion: v1
- kind: Service
- metadata:
- labels:
- etcd_node: etcd1
- name: etcd1
- spec:
- ports:
- - name: client
- port: 2379
- protocol: TCP
- targetPort: 2379
- - name: server
- port: 2380
- protocol: TCP
- targetPort: 2380
- selector:
- etcd_node: etcd1
- ---
- apiVersion: v1
- kind: Pod
- metadata:
- labels:
- app: etcd
- etcd_node: etcd2
- name: etcd2
- spec:
- containers:
- - command:
- - /etcd
- - --name
- - etcd2
- - --initial-advertise-peer-urls
- - http://etcd2:2380
- - --listen-peer-urls
- - http://0.0.0.0:2380
- - --listen-client-urls
- - http://0.0.0.0:2379
- - --advertise-client-urls
- - http://etcd2:2379
- - --initial-cluster
- - etcd0=http://etcd0:2380,etcd1=http://etcd1:2380,etcd2=http://etcd2:2380
- - --initial-cluster-state
- - new
- image: quay.io/coreos/etcd:latest
- name: etcd2
- ports:
- - containerPort: 2379
- name: client
- protocol: TCP
- - containerPort: 2380
- name: server
- protocol: TCP
- restartPolicy: Never
- ---
- apiVersion: v1
- kind: Service
- metadata:
- labels:
- etcd_node: etcd2
- name: etcd2
- spec:
- ports:
- - name: client
- port: 2379
- protocol: TCP
- targetPort: 2379
- - name: server
- port: 2380
- protocol: TCP
- targetPort: 2380
- selector:
- etcd_node: etcd2
|