Skip to content

Issues when running Quickstart and kind #1195

@alexandertuna

Description

@alexandertuna

Hi submariners,

Thanks for your software and for a helpful quickstart guide. @iperezx and I encountered two issues while trying quickstart/kind/ on our Mac laptops. I write them here in case you're interested or have a suggestion on something we could've done differently.

I'm sorry in advance if these are known and/or we're doing something dumb. Please let me know if I can provide any more info which would be helpful to you.

Thanks again!
-Alex


  1. Location of .docker inside the docker container

Deploying automatically has an error:

make deploy using=lighthouse 2>&1 | tee log.txt
Cannot connect to the Docker daemon at unix:///Users/atuna/.docker/run/docker.sock. Is the docker daemon running?.

Log: log.make_deploy_docker.txt

However, the docker daemon is running normally at that path. We think the problem is: this path is unavailable within the docker container when make deploy is running. We worked around this by changing the mount path in .dapper:

#
# File: .dapper
#
# From:
if [ -d "${HOME}/.docker" ]; then
    dockerargs="${dockerargs} -v ${HOME}/.docker:/root/.docker${suffix}"
fi

# To:
if [ -d "${HOME}/.docker" ]; then
    dockerargs="${dockerargs} -v ${HOME}/.docker:${HOME}/.docker${suffix}"
fi

With this change, automatic deployment ran fine.


  1. kubectl can't communicate with clusters

After deploying, kubectl is unable to communicate with the clusters:

> export KUBECONFIG=output/kubeconfigs/kind-config-cluster1:output/kubeconfigs/kind-config-cluster2
> kubectl --kubeconfig output/kubeconfigs/kind-config-cluster2 get pods
E1010 16:38:22.509079   66771 memcache.go:265] "Unhandled Error" err="couldn't get current server API group list: Get \"https://172.18.0.7:6443/api?timeout=32s\": dial tcp 172.18.0.7:6443: i/o timeout"

We think this is because the kube configs refer to an address:port which is only accessible inside the kind containers. But our intention is to operate kubectl outside the containers. So we changed the server attribute of the kube configs to use the address:port accessible from outside the containers.

#
# File: output/kubeconfigs/kind-config-cluster2
# Same logic applies to kind-config-cluster1
#
# From:
server: https://172.18.0.7:6443
# To:
server: https://127.0.0.1:43411

The address:port were provided by:

bash-3.2$ docker ps
CONTAINER ID   IMAGE                  COMMAND                  CREATED          STATUS          PORTS                       NAMES
ad50b30bd1d0   kindest/node:v1.31.0   "/usr/local/bin/entr…"   10 minutes ago   Up 10 minutes   127.0.0.1:43411->6443/tcp   cluster2-control-plane
9a0c9543ba1a   kindest/node:v1.31.0   "/usr/local/bin/entr…"   10 minutes ago   Up 10 minutes   127.0.0.1:34251->6443/tcp   cluster1-control-plane
c5e92aa09550   kindest/node:v1.31.0   "/usr/local/bin/entr…"   10 minutes ago   Up 10 minutes                               cluster1-worker
20f7a837cd54   kindest/node:v1.31.0   "/usr/local/bin/entr…"   10 minutes ago   Up 10 minutes                               cluster2-worker
b1356c4106eb   registry:2             "/entrypoint.sh /etc…"   10 minutes ago   Up 10 minutes   127.0.0.1:5000->5000/tcp    kind-registry
bash-3.2$

With this change, we can communicate with the containers.


Info about my setup:

bash-3.2$ sw_vers
ProductName:		macOS
ProductVersion:		14.6.1
BuildVersion:		23G93
bash-3.2$ sysctl -n machdep.cpu.brand_string && sysctl hw.memsize
Apple M3
hw.memsize: 8589934592
bash-3.2$ uname -m
arm64
bash-3.2$ uname -r
23.6.0
bash-3.2$ uname -a
Darwin Alexanders-MacBook-Pro.local 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:14:04 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_T8122 arm64
bash-3.2$
bash-3.2$ pwd
/Users/atuna/work/submariner_quickstart/submariner-operator
bash-3.2$ git log -1 --oneline
8e6ac559 (HEAD -> devel, origin/devel, origin/HEAD) Bump golang.org/x/net from 0.29.0 to 0.30.0
bash-3.2$ docker version
Client: Docker Engine - Community
 Version:           27.2.0
 API version:       1.47
 Go version:        go1.23.0
 Git commit:        3ab4256958
 Built:             Tue Aug 27 14:08:11 2024
 OS/Arch:           darwin/arm64
 Context:           desktop-linux
bash-3.2$

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions