gcloud config set compute/zone us-east1-d
gcloud container clusters get-credentials cluster-1
apiVersion: extensions/v1beta1kind: Deploymentmetadata: name: exhibitorspec: replicas: 3 template: metadata: labels: name: exhibitor spec: containers: - image: mbabineau/zookeeper-exhibitor imagePullPolicy: Always name: exhibitor volumeMounts: - name: nfs mountPath: "/opt/zookeeper/local_configs" livenessProbe: tcpSocket: port: 8181 initialDelaySeconds: 60 timeoutSeconds: 1 readinessProbe: httpGet: path: /exhibitor/v1/cluster/4ltr/ruok port: 8181 initialDelaySeconds: 120 timeoutSeconds: 1 env: - name: HOSTNAME valueFrom: fieldRef: fieldPath: status.podIP volumes: - name: nfs nfs: server: singlefs-1-vm path: /data---apiVersion: v1kind: Servicemetadata: name: exhibitor labels: name: exhibitorspec: ports: - port: 2181 protocol: TCP name: zk - port: 8181 protocol: TCP name: api selector: name: exhibitor
kubectl apply -f exhibitor.yaml
kubectl get pods -w
kubectl proxy &
export PROXY_URL=http://localhost:8001/api/v1/proxy/export EXHIBITOR_URL=${PROXY_URL}namespaces/default/services/exhibitor:8181export STATUS_URL=${EXHIBITOR_URL}/exhibitor/v1/cluster/statusexport STATUS=`curl -s $STATUS_URL`echo $STATUS | jq '.[] | {hostname: .hostname, leader: .isLeader}'
Use promo code NEXT1720 to save $300 off general admission