seaweedfs-operator icon indicating copy to clipboard operation
seaweedfs-operator copied to clipboard

Make deploy issue (with/without webhook)

Open ghost opened this issue 5 years ago • 10 comments

without webhook:

logs:

 kube-rbac-proxy I1127 18:04:05.779961       1 main.go:186] Valid token audiences:                                                                                                                                    │
│ kube-rbac-proxy I1127 18:04:05.780103       1 main.go:232] Generating self signed cert as no cert is provided                                                                                                        │
│ kube-rbac-proxy I1127 18:04:08.411282       1 main.go:281] Starting TCP socket on 0.0.0.0:8443                                                                                                                       │
│ kube-rbac-proxy I1127 18:04:08.411962       1 main.go:288] Listening securely on 0.0.0.0:8443                                                                                                                        │
│ manager 2020-11-27T18:04:09.577Z    INFO    controller-runtime.metrics    metrics server is starting to listen    {"addr": "127.0.0.1:8080"}                                                                         │
│ manager 2020-11-27T18:04:09.578Z    INFO    controller-runtime.builder    Registering a mutating webhook    {"GVK": "seaweed.seaweedfs.com/v1, Kind=Seaweed", "path": "/mutate-seaweed-seaweedfs-com-v1-seaweed"}    │
│ manager 2020-11-27T18:04:09.578Z    INFO    controller-runtime.webhook    registering webhook    {"path": "/mutate-seaweed-seaweedfs-com-v1-seaweed"}                                                                │
│ manager 2020-11-27T18:04:09.578Z    INFO    controller-runtime.builder    Registering a validating webhook    {"GVK": "seaweed.seaweedfs.com/v1, Kind=Seaweed", "path": "/validate-seaweed-seaweedfs-com-v1-seaweed" │
│ manager 2020-11-27T18:04:09.578Z    INFO    controller-runtime.webhook    registering webhook    {"path": "/validate-seaweed-seaweedfs-com-v1-seaweed"}                                                              │
│ manager 2020-11-27T18:04:09.578Z    INFO    setup    starting manager                                                                                                                                                │
│ manager I1127 18:04:09.579075       1 leaderelection.go:242] attempting to acquire leader lease  seaweedfs-operator-system/674006ec.seaweedfs.com...                                                                 │
│ manager 2020-11-27T18:04:09.615Z    INFO    controller-runtime.manager    starting metrics server    {"path": "/metrics"}                                                                                            │
│ manager 2020-11-27T18:04:09.615Z    INFO    controller-runtime.webhook.webhooks    starting webhook server                                                                                                           │
│ manager 2020-11-27T18:04:09.616Z    DEBUG    controller-runtime.manager    non-leader-election runnable finished    {"runnable type": "*webhook.Server"}                                                             │
│ manager 2020-11-27T18:04:09.616Z    ERROR    setup    problem running manager    {"error": "open /tmp/k8s-webhook-server/serving-certs/tls.crt: no such file or directory"}                                          │
│ manager github.com/go-logr/zapr.(*zapLogger).Error                                                                                                                                                                   │
│ manager     /go/pkg/mod/github.com/go-logr/[email protected]/zapr.go:128                                                                                                                                                   │
│ manager main.main                                                                                                                                                                                                    │
│ manager     /workspace/main.go:89                                                                                                                                                                                    │
│ manager runtime.main                                                                                                                                                                                                 │
│ manager     /usr/local/go/src/runtime/proc.go:203                                                                                                                                                                    │
│ manager stream closed                                                  

with webhook

describe:

 Events:                                                                                                                                                                                                              │
│   Type     Reason       Age               From                        Message                                                                                                                                        │
│   ----     ------       ----              ----                        -------                                                                                                                                        │
│   Normal   Scheduled    <unknown>         default-scheduler           Successfully assigned seaweedfs-operator-system/seaweedfs-operator-controller-manager-5556b4b666-df5vb to rke-1.uk                    │
│   Warning  FailedMount  21s               kubelet, rke-1.uk  MountVolume.SetUp failed for volume "default-token-hqgnx" : failed to sync secret cache: timed out waiting for the condition                   │
│   Warning  FailedMount  21s               kubelet, rke-1.uk  MountVolume.SetUp failed for volume "cert" : failed to sync secret cache: timed out waiting for the condition                                  │
│   Warning  FailedMount  5s (x5 over 20s)  kubelet, rke-1.uk  MountVolume.SetUp failed for volume "cert" : secret "webhook-server-cert" not found                    

Am I getting this right that I need to have csi & cert-manager installed in the cluster in order to deploy operator?

ghost avatar Nov 27 '20 18:11 ghost

Need steps to reproduce

chrislusf avatar Nov 27 '20 19:11 chrislusf

Need steps to reproduce

git clone https://github.com/seaweedfs/seaweedfs-operator --depth=1 cd seaweedfs-operator make deploy

cluster - https://docs.rke2.io/install/quickstart/ ; I am thinking, maybe its cause of rke2?

ghost avatar Nov 27 '20 19:11 ghost

can you try https://kind.sigs.k8s.io/ ?

chrislusf avatar Nov 27 '20 19:11 chrislusf

can you try https://kind.sigs.k8s.io/ ?

I could not try that locally though. However, I tried that on kubespray cluster and got the same errors.

ghost avatar Nov 27 '20 23:11 ghost

I do not have kubespray cluster and do not know how to help.

chrislusf avatar Nov 28 '20 00:11 chrislusf

I do not have kubespray cluster and do not know how to help.

I will try with Kind local cluster tomorrow. However, I ve also tried to deploy seaweedfs via helm chart in main repo and it didnt work either, seems like the chart is broken as well.

ghost avatar Nov 28 '20 00:11 ghost

However, I ve also tried to deploy seaweedfs via helm chart in main repo and it didnt work either, seems like the chart is broken as well.

Need steps to reproduce. please create a separate issue.

chrislusf avatar Nov 28 '20 00:11 chrislusf

Need steps to reproduce

git clone https://github.com/seaweedfs/seaweedfs-operator --depth=1 cd seaweedfs-operator make deploy

cluster - https://docs.rke2.io/install/quickstart/ ; I am thinking, maybe its cause of rke2?

Sorry for the missing details in the README. You have to install a cert-manager in your cluster if you want to enable webhooks. Otherwise, you have to add an environment variable named ENABLE_WEBHOOKS and value "false" in the Deployment of seaweedfs-operator/config/manager/manager.yaml: https://github.com/seaweedfs/seaweedfs-operator/blob/b0f384e3e956e03b390f708e2b3b8bf88d9f75c7/config/manager/manager.yaml#L31-L33

howardlau1999 avatar Nov 28 '20 01:11 howardlau1999

Need steps to reproduce

git clone https://github.com/seaweedfs/seaweedfs-operator --depth=1 cd seaweedfs-operator make deploy cluster - https://docs.rke2.io/install/quickstart/ ; I am thinking, maybe its cause of rke2?

Sorry for the missing details in the README. You have to install a cert-manager in your cluster if you want to enable webhooks. Otherwise, you have to add an environment variable named ENABLE_WEBHOOKS and value "false" in the Deployment of seaweedfs-operator/config/manager/manager.yaml:

https://github.com/seaweedfs/seaweedfs-operator/blob/b0f384e3e956e03b390f708e2b3b8bf88d9f75c7/config/manager/manager.yaml#L31-L33

http://paste.openstack.org/show/800934/ - still getting the same issue.

ghost avatar Dec 10 '20 13:12 ghost

same here

chukynax avatar Jun 21 '21 15:06 chukynax