在minikube上配置kafka + minio

时间:2018-07-24 00:32:43

标签: apache-kafka minikube minio

我想在我的minikube(v0.28.0)上运行minio resize函数。 我安装了kubekess(v0.6.0),并使用该版本随附的yaml文件(kafka-zookeeper-v0.6.0.yaml)部署了kafka。

我在these steps之后安装了minio。 我也在.minio / config.json中mc并启用了kafka 每件事似乎都正确部署。

$ kubectl get services
  NAME           TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)             AGE
  broker         ClusterIP   None             <none>        9092/TCP            2d
  kafka          ClusterIP   10.98.179.36     <none>        9092/TCP            2d
  kubernetes     ClusterIP   10.96.0.1        <none>        443/TCP             6d
  minio          ClusterIP   None             <none>        9000/TCP            3d
  minio-public   ClusterIP   10.101.140.13    <none>        9000/TCP            3d
  zoo            ClusterIP   None             <none>        9092/TCP,3888/TCP   2d
  zookeeper      ClusterIP   10.107.189.185   <none>        2181/TCP            2d
$ kubectl get pods
  NAME                     READY     STATUS    RESTARTS   AGE
  hello-696b7f4964-894d5   1/1       Running   2          4d
  kafka-0                  1/1       Running   3          2d
  minio-0                  1/1       Running   1          3d
  minio-1                  1/1       Running   1          3d
  minio-2                  1/1       Running   1          3d
  minio-3                  1/1       Running   1          3d
  zoo-0                    1/1       Running   1          2d
$ kubectl get deployments
  NAME                       DESIRED   CURRENT   UP-TO-DATE   AVAILABLE   AGE
  kafka-trigger-controller   1         0         0            0           2d

但是我无法将事件添加到本地微型设备中。这是错误。

$ mc events add localminio/foobar arn:minio:sqs:us-east-1:1:kafka --events put
 mc: <ERROR> Cannot enable notification on the specified bucket. A specified destination ARN does not exist or is not well-formed. Verify the destination ARN.

1 个答案:

答案 0 :(得分:0)

@ user1027336 ARN似乎是正确的。唯一的错误是,如果config.json中的kafka部分设置不正确或kafka设置不正确。我发现https://linuxhint.com/install-apache-kafka-ubuntu/对在Ubuntu计算机上安装public function test() { return $this->createQueryBuilder('user') ->select('user.id, user.email, user.username') ->getQuery() ->getResult(); // will return objects // ->getArrayResult() -> will return array of arrays } 很有帮助。就config.json而言,

这就是我所拥有的

kafka

https://blog.minio.io/part-6-6-publish-minio-events-via-kafka-83aa606ffb65很好地说明了如何通过minio启用kafka