结合helm部署banzaicloud kafka operator,含zookeeper集群

独自空忆成欢 提交于 2020-03-23 00:45:44

确保有默认的StorageClass(NFS),以及部署过Prometheus-operator(0.33)和helm(2.13.x)
570 2019-12-03 09:34:14 cd /usr/local/src/
571 2019-12-03 09:34:14 ll
572 2019-12-03 09:34:17 cd /opt/k8s/
573 2019-12-03 09:34:18 ll
574 2019-12-03 09:34:39 git clone https://github.com/pravega/zookeeper-operator
575 2019-12-03 09:34:49 yum install git -y
576 2019-12-03 09:35:08 git clone https://github.com/pravega/zookeeper-operator
577 2019-12-03 09:35:44 cd zookeeper-operator/
578 2019-12-03 09:35:45 ll
579 2019-12-03 09:35:46 cd deploy/
580 2019-12-03 09:35:47 ll
581 2019-12-03 09:35:49 cd crds/
582 2019-12-03 09:35:50 ll
583 2019-12-03 09:36:01 kubectl apply -f zookeeper_v1beta1_zookeepercluster_crd.yaml
584 2019-12-03 09:36:08 cd ../default_ns/
585 2019-12-03 09:36:09 ll
586 2019-12-03 09:36:21 kubectl apply -f rbac.yaml
587 2019-12-03 09:36:28 kubectl apply -f operator.yaml
588 2019-12-03 09:36:34 kubectl get pod -o wide
589 2019-12-03 09:37:36 kubectl describe pod zookeeper-operator-8449df9744-gdckf
590 2019-12-03 09:37:40 kubectl get pod -o wide
591 2019-12-03 09:39:19 cd ../crds/
592 2019-12-03 09:39:19 ll
593 2019-12-03 09:39:22 cat zookeeper_v1beta1_zookeepercluster_cr.yaml
594 2019-12-03 09:39:36 vim zookeeper_v1beta1_zookeepercluster_cr.yaml
595 2019-12-03 09:40:05 kubectl apply -f zookeeper_v1beta1_zookeepercluster_cr.yaml
596 2019-12-03 09:40:13 kubectl get pod -o wide
597 2019-12-03 09:41:05 kubectl describe pod zookeeper-0
598 2019-12-03 09:42:00 cat ../default_ns/operator.yaml
599 2019-12-03 09:43:05 kubectl describe pod zookeeper-0
600 2019-12-03 09:43:11 kubectl get pod -o wide
601 2019-12-03 09:43:17 kubectl describe pod zookeeper-0
602 2019-12-03 09:43:22 kubectl get pod -o wide
603 2019-12-03 10:00:32 kubectl get zk
604 2019-12-03 10:00:53 kubectl get all -l app=example
605 2019-12-03 10:00:59 kubectl get all -l app=zookeeper
606 2019-12-03 10:03:07 kubectl get pod -A -o wide
607 2019-12-03 10:05:18 cd ..
608 2019-12-03 10:05:23 ll
609 2019-12-03 10:05:34 mkdir cert-manager
610 2019-12-03 10:05:36 cd cert
611 2019-12-03 10:05:41 cd ../cert-manager/
612 2019-12-03 10:05:44 cd ..
613 2019-12-03 10:05:46 cd cert
614 2019-12-03 10:05:46 ll
615 2019-12-03 10:05:52 cd ../cert-manager/
616 2019-12-03 10:05:53 ll
617 2019-12-03 10:06:19 wget https://github.com/jetstack/cert-manager/releases/download/v0.11.0/cert-manager.yaml
618 2019-12-03 10:06:25 ll
619 2019-12-03 10:06:28 cat cert-manager.yaml
620 2019-12-03 10:06:50 vim cert-manager.yaml
621 2019-12-03 10:12:22 ll
622 2019-12-03 10:12:30 kubectl apply -f cert-manager.yaml
623 2019-12-03 10:15:06 vim cert-manager.yaml
624 2019-12-03 10:19:38 kubectl apply -f cert-manager.yaml
625 2019-12-03 10:19:45 kubectl apply -f cert-manager.yaml --validate=false
626 2019-12-03 10:20:19 kubectl get pod -A -o wide
627 2019-12-03 10:25:14 cd ..
628 2019-12-03 10:25:22 git clone https://github.com/banzaicloud/kafka-operator
629 2019-12-03 10:28:28 cd kafka-operator/
630 2019-12-03 10:28:29 ll
631 2019-12-03 10:28:46 cd config/
632 2019-12-03 10:28:46 ll
633 2019-12-03 10:28:48 cd samples/
634 2019-12-03 10:28:50 ll
635 2019-12-03 10:29:07 cd ..
636 2019-12-03 10:29:10 ll
637 2019-12-03 10:29:20 make deploy
这里由于我没安装go语言环境,显然不能编译成功,改为helm安装
后来安装了go语言环境后自己编译,发现不成功,参见前一篇博客
638 2019-12-03 10:32:16 helm repo add banzaicloud-stable https://kubernetes-charts.banzaicloud.com/
639 2019-12-03 10:32:31 cd config/
640 2019-12-03 10:32:32 ll
641 2019-12-03 10:32:34 cd samples/
642 2019-12-03 10:32:35 ll
643 2019-12-03 10:32:48 cat example-prometheus-alerts.yaml
644 2019-12-03 10:33:33 helm install --name=kafka-operator banzaicloud-stable/kafka-operator -f example-prometheus-alerts.yaml
645 2019-12-03 10:34:20 kubectl get pod -o wide
646 2019-12-03 10:34:39 kubectl describe pod kafka-operator-operator-598d7568f9-vm7md
647 2019-12-03 10:40:12 kubectl get pod -o wide
648 2019-12-03 10:40:26 ll
649 2019-12-03 10:40:35 vim simplekafkacluster.yaml
650 2019-12-03 10:42:05 kubectl get svc
651 2019-12-03 10:42:36 vim simplekafkacluster.yaml
652 2019-12-03 10:43:18 kubectl apply -f simplekafkacluster.yaml
653 2019-12-03 10:43:27 kubectl get pod -o wide
654 2019-12-03 10:44:02 ll
655 2019-12-03 10:44:20 cat kafkacluster-prometheus.yaml
656 2019-12-03 10:44:49 kubectl apply -f kafkacluster-prometheus.yaml
657 2019-12-03 10:44:56 kubectl get pod -o wide
658 2019-12-03 10:46:11 kubectl describe pod kafka4jjkx
659 2019-12-03 10:46:50 vim simplekafkacluster.yaml
660 2019-12-03 10:51:15 kubectl describe pod kafka4jjkx
661 2019-12-03 10:51:26 kubectl get pod -o wide
662 2019-12-03 10:51:58 kubectl describe pod kafka4jjkx
663 2019-12-03 10:52:07 kubectl get pod -o wide
664 2019-12-03 10:54:57 kubectl describe pod kafka4jjkx
▽ 665 2019-12-03 10:55:07 ll
666 2019-12-03 10:55:43 kubectl describe pod kafka4jjkx
667 2019-12-03 10:55:59 kubectl get pod -o wide
668 2019-12-03 10:59:18 kubectl describe pod kafka6cb9g
669 2019-12-03 10:59:36 kubectl get pod -o wide
670 2019-12-03 11:00:39 kubectl describe pod kafka4jjkx
671 2019-12-03 11:01:32 kubectl get pod -o wide

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!