https://rancher.com/ logo
Docs
Join the conversationJoin Slack
Channels
academy
amazon
arm
azure
cabpr
chinese
ci-cd
danish
deutsch
developer
elemental
epinio
espanol
events
extensions
fleet
français
gcp
general
harvester
harvester-dev
hobbyfarm
hypper
japanese
k3d
k3os
k3s
k3s-contributor
kim
kubernetes
kubewarden
lima
logging
longhorn-dev
longhorn-storage
masterclass
mesos
mexico
nederlands
neuvector-security
office-hours
one-point-x
onlinemeetup
onlinetraining
opni
os
ozt
phillydotnet
portugues
rancher-desktop
rancher-extensions
rancher-setup
rancher-wrangler
random
rfed_ara
rio
rke
rke2
russian
s3gw
service-mesh
storage
submariner
supermicro-sixsq
swarm
terraform-controller
terraform-provider-rancher2
terraform-provider-rke
theranchcast
training-0110
training-0124
training-0131
training-0207
training-0214
training-1220
ukranian
v16-v21-migration
vsphere
windows
Powered by Linen
k3d
  • w

    wide-garage-9465

    02/02/2023, 1:19 PM
    https://github.com/k3d-io/k3d/releases/tag/v5.4.7
    🎉 1
  • p

    polite-engineer-55788

    02/02/2023, 6:58 PM
    @wide-garage-9465 do we have examples on how to use
    rancher/k3d:x-dind
    image ? I want to start a k3d cluster without mounting host docker sock
    w
    • 2
    • 5
  • p

    polite-engineer-55788

    02/03/2023, 7:49 AM
    why there is no checksum for https://github.com/k3d-io/k3d/releases ?
    w
    • 2
    • 6
  • p

    polite-engineer-55788

    02/05/2023, 10:11 AM
    any thoughts on https://rancher-users.slack.com/archives/CGGQEHPPW/p1675591781414439?
  • f

    future-vase-71145

    02/10/2023, 7:01 PM
    We're using k3d locally and are upgrading from 4.4.6 to 5.4.6. With 4.4.6 we mounted an updated coredns configmap to /var/lib/rancher/k3s/server/manifests/d-coredns-patch.yaml so that we could add
    rewrite name regex (.*).<http://local.example.com|local.example.com> public-nginx-ingress-nginx-controller.default.svc.cluster.local
    . (Everything else was kept default.) It appears from my reading of github issues that modifying the
    .:53
    block in coredns is no longer supported? Any pointers on how to handle this? For now I'm doing this, but it feels... wrong.
    kubectl -n kube-system patch configmap coredns --patch-file "coredns-patch.yaml"
    kubectl wait --for=condition=Ready=true pod -l k8s-app=kube-dns -n kube-system
    kubectl -n kube-system rollout restart deployment coredns
    w
    • 2
    • 22
  • h

    handsome-salesclerk-54324

    02/12/2023, 8:28 PM
    Is there a list of storage providers known to work with k3d/k3d?
  • c

    chilly-toddler-80124

    02/14/2023, 2:52 PM
    hi! I try to understand the k3d (k3s). It is a lightweight kubernetes, it is okay.

    https://static.wixstatic.com/media/6f3936_2ce31d23816f43fb995912c961149785~mv2.png/v1/f[…]1,enc_auto/6f3936_2ce31d23816f43fb995912c961149785~mv2.png▾

    https://k3d.io/ Guides So, On a machine (laptop) I can run it with docker. Pre-requirements: docker, kubectl The "install.sh" setup the environment: cluster with nodes. Master Node (Control Plane): Loadbalancer + Nginx Proxy Worker Nodes: k3d-test-server-0 ... k3d-test-agent-0 ... what are the k3d-test-server-X and k3d-test-agent-X? What is the difference the server and agent?
    w
    • 2
    • 1
  • c

    chilly-toddler-80124

    02/14/2023, 7:54 PM
    K3D has no web interface? Can I use only the K3X?
    w
    • 2
    • 23
  • b

    bulky-fish-74730

    02/21/2023, 10:43 AM
    Good day. When I install k3d, create a default cluster and then run
    kubectl cluster-info
    I get a couple of messages like
    memcache.go:255] couldn't get resource list for <http://metrics.k8s.io/v1beta1|metrics.k8s.io/v1beta1>: the server is currently unable to handle the request
  • v

    victorious-mouse-54341

    02/21/2023, 6:07 PM
    I have (what I hope) is a really easy question. I'm launching a k3d cluster using the following command:
    k3d cluster create doctorconsul --network doctorconsul_wan --api-port 127.0.0.1:6443 --k3s-arg="--disable=traefik@server:0" -p "8502:443@loadbalancer"
    This works pretty much exactly as expected. It drops into my "doctorconsul_wan" network that is already built in docker compose. The problem I'm having is that the external-IP used is dynamically the first available in that network (192.168.1.7 in my case) and I need to statically assign it (to 192.169.1.10). I'm not seeing a parameter to do so. I have a feeling that perhaps I have to pass a kube native config param through via
    --kubeconfig-update-default
    , but frankly I don't know nearly enough about kube to figure that out. Any help is much appreciated. Thanks!
    • 1
    • 7
  • v

    victorious-mouse-54341

    02/21/2023, 9:51 PM
    Alright. So modifying the server node IPs appears to have NOT actually worked. it changes the server IPs, but everything is broken. when I use this syntax:
    k3d cluster create doctorconsul --network doctorconsul_wan \
        --api-port 127.0.0.1:6443 \
        -p "8502:443@loadbalancer" \
        --k3s-arg="--disable=traefik@server:0" \
        --k3s-arg="--node-ip=192.169.7.10@server:0" \
        --k3s-arg="-node-external-ip=192.169.7.10@server:0"
    The only server node does correctly have these IPs
    Addresses:                                                                                                                                                                                                                                                                ││   InternalIP:  192.169.7.10                                                                                                                                                                                                                                               ││   ExternalIP:  192.169.7.10                                                                                                                                                                                                                                               ││   Hostname:    k3d-doctorconsul-server-0
    But coreDNS won't come up.
    [INFO] plugin/ready: Still waiting on: "kubernetes"                                                                                                      
    [WARNING] plugin/kubernetes: Kubernetes API connection failure: Get "<https://10.43.0.1:443/version>": dial tcp 10.43.0.1:443: connect: no route to host
    ^^^ These are just repeatedly spammed. Anyone know why? I'm way out of my kube league and I'm just trying to get K3d to accept a static IP instead of choosing the first avail dynamically. Thanks
    w
    • 2
    • 2
  • a

    adamant-garage-54388

    02/22/2023, 3:37 AM
    Hi Everyone, hope you guys are doing great. This is my first time installing k3d and what I'm seeing is that even though k3d installation was successful, all the pods are in pending state. Am I missing something here?
    w
    • 2
    • 1
  • r

    rough-farmer-49135

    02/22/2023, 7:32 PM
    I'm trying to use k3d to run an application on some shared lab (read "wild west with nearly everyone having root") machines. The owners of the machines are required to do some vulnerability scans that are finding things inside /var/lib/docker/volumes , overlay2 , etc and are sending out "hey guys, fix these" e-mails. they took a pass at trying to translate from the location to the image container and some of them were definite offenders but others were unrelated. I think the method they used was just with the docker command. I just spent an hour or two poking around trying to get at the internals of which container were what using docker & ctr commands with a k3d cluster running and wasn't having a lot of luck. Anyone know if I could've gotten to things if I'd just used nerdctl or crictl or checked the right spot in kubectl or some other tool? I didn't spot anything on k3d.io and thought I'd ask if anyone knows before I go experimenting with the different tools or even spelunking through odd spots in Linux.
    c
    • 2
    • 7
  • r

    rough-farmer-49135

    02/24/2023, 2:53 AM
    I know with RKE2 sometimes you can query some items with crictl (I think it's the static pods only). Does K3D run anything with crio such that it could be queried with crictl too?
    c
    • 2
    • 7
  • a

    aloof-oxygen-4191

    02/27/2023, 8:24 AM
    Hello, Gm How can I enable CpuManager please on k3d ?
    --k3s-server-arg '--kube-apiserver-arg=feature-gates=CPUManager=true --cpu-manager-policy=static'
    maybe ?
    c
    • 2
    • 3
  • f

    fancy-river-86403

    02/27/2023, 1:50 PM
    Hi, I am trying to run a k3d cluster for the first time, and like other users, all the pods are in pending state. However, this doesn't seem to be the same problem as https://github.com/k3d-io/k3d/issues/1229, I don't see the same error. Any hints on how to debug this ? I'm on Ubuntu 22.10 with a ZFS filesystem, and after reading k3d and k3s issues with ZFS, I'm not sure whether ZFS is supported now or not ?
    b
    • 2
    • 5
  • r

    refined-memory-51625

    03/02/2023, 4:34 PM
    if I wanted to create (or edit) a k3d cluster's kube-control-manager so that I can set
    --horizontal-pod-autoscaler-sync-period
    , what's the proper way to do this?
    • 1
    • 1
  • m

    mammoth-laptop-63191

    03/04/2023, 6:15 PM
    Hi experts, I created a kubernetes cluster using k3d on one VM and I want to add other 20 VMs as worker nodes to this cluster. Is this feasible?
    w
    • 2
    • 2
  • g

    glamorous-needle-18908

    03/05/2023, 10:18 AM
    Greetings everyone, I am currently attempting to configure the Traefik ingress on my k3d cluster, but I have exhausted all possible solutions and still cannot get it to work. My system specifications include a Macbook M1 running k3d version v5.4.6 - k3s version v1.24.6-k3s1 (default). To expose services via ingress through the defined loadbalancer
    k3d cluster create ingress --servers 1 --agents 3 -p "80:80@loadbalancer" -p "443:443@loadbalancer"
    , I have attempted several approaches but without success. Every Service is working correctly and I can access the port by forwarding the pod or the service only when trying to access the ingress I get a 404 error. This is the case for everything exposed through the ingress. I would appreciate any input or suggestions on how to resolve this issue. 🙂
    w
    • 2
    • 1
  • h

    handsome-salesclerk-54324

    03/05/2023, 3:32 PM
    When I run:
    k3d cluster create westie --api-port 127.0.0.1:6445 --servers 3 --agents 2 --volume '/home/mwoodpatrick/projects/git/westie-dev-pnpm:/westie-dev-pnpm@agent[*]' --port '8
    080:80@loadbalancer'
    I'm getting the error below, what am I doing wrong:
    FATA[0000] failed to filter nodes for volume mapping '/home/mwoodpatrick/projects/git/westie-dev-pnpm:/westie-dev-pnpm': Failed to parse node filters: invalid format or empty subset in 'agent[*]'
    w
    • 2
    • 2
  • a

    aloof-oxygen-4191

    03/06/2023, 8:11 AM
    Gm When i create k3d (v5.4.7) with cli args, all is fine when i create using a yaml, it cant join the agents docker logs on the agents show
    error dialing load balancer servers: all servers failed
    even that
    disableLoadbalancer: true
    (not sure related to the error ?) my yaml is (if some values are needed will supply)
    <https://termbin.com/sw7km6>
    trying to make it more minimal meanwhile CLI command that works
    k3d cluster create $CLUSTER_NAME --registry-use $REGISTRY_NAME \
            --api-port $KUBERNETES_SERVICE_HOST:$KUBERNETES_SERVICE_PORT \
            --servers=$KUBEVIRT_NUM_SERVERS \
            --agents=$KUBEVIRT_NUM_AGENTS \
            --k3s-arg "--disable=traefik@server:0" \
            --no-lb \
            --k3s-arg "--flannel-backend=none@server:*" \
            --k3s-arg "--kubelet-arg=cpu-manager-policy=static@agent:*" \
            --k3s-arg "--kubelet-arg=kube-reserved=cpu=500m@agent:*" \
            --k3s-arg "--kubelet-arg=system-reserved=cpu=500m@agent:*" \
            --volume "$(pwd)/cluster-up/cluster/k3d/manifests/calico.yaml:/var/lib/rancher/k3s/server/manifests/calico.yaml@server:0" \
            -v /dev/vfio:/dev/vfio@agent:* \
            -v /lib/modules:/lib/modules@agent:* \
            -v ${id1}:/etc/machine-id@server:0 \
            -v ${id2}:/etc/machine-id@agent:0 \
            -v ${id3}:/etc/machine-id@agent:1
    Thanks
    w
    • 2
    • 9
  • h

    handsome-salesclerk-54324

    03/11/2023, 12:59 PM
    I'm running k3d v5.4.8 on WSL-2 1.1.3.0 which was working previously but when I set
    export KUBECONFIG=/home/mwoodpatrick/.k3d/kubeconfig-local-k8s.yaml
    and run
    kubectl version
    I get
    Client Version: <http://version.Info|version.Info>{Major:"1", Minor:"20", GitVersion:"v1.20.15", GitCommit:"8f1e5bf0b9729a899b8df86249b56e2c74aebc55", GitTreeState:"clean", BuildDate:"2022-01-20T02:28:14Z", GoVersion:"go1.15.15", Compiler:"gc", Platform:"linux/amd64"}
    Unable to connect to the server: context deadline exceeded
    docker ps shows that the server and load balancer are running and I can use docker to exec into the server If I run
    k3s kubectl version
    I get:
    WARNING: This version information is deprecated and will be replaced with the output from kubectl version --short.  Use --output=yaml|json to get the full version.
    Client Version: <http://version.Info|version.Info>{Major:"1", Minor:"25", GitVersion:"v1.25.6+k3s1", GitCommit:"9176e03c5788e467420376d10a1da2b6de6ff31f", GitTreeState:"clean", BuildDate:"2023-01-26T00:47:47Z", GoVersion:"go1.19.5", Compiler:"gc", Platform:"linux/amd64"}
    Kustomize Version: v4.5.7
    error: Get "<https://0.0.0.0:34117/version?timeout=32s>": context deadline exceeded - error from a previous attempt: EOF
    Any suggestions on the best way to debug what the issue is?
    w
    • 2
    • 8
  • c

    cold-ambulance-6848

    03/13/2023, 5:12 PM
    Howdy! Just wanted to say a big thanks to the k3d team 😄 I'm using it with Docker in Docker to create multiple web-based lab environments and it works amazingly
    w
    • 2
    • 1
  • h

    handsome-salesclerk-54324

    03/19/2023, 10:23 AM
    Is anyone using the Microsoft Kubernetes vscode extension with k3d seems like this extension could be useful but its complaining that it can't find kubectl even though its in my path and I specified the path to it in vs-kubernetes.kubectl-path.linux. Anyone know what's the minimal configuration for this extension it seems like its minikube centric which is unfortunate.
  • b

    bright-pizza-38404

    03/19/2023, 12:55 PM
    Hello, does k3d works with docker-desktop on fedora or docker-engine only?
    w
    • 2
    • 1
  • a

    aloof-oxygen-4191

    03/21/2023, 3:41 PM
    Hi Is someone familiar with this issue maybe ? https://github.com/kubernetes/kubectl/issues/1363#issuecomment-1478063593 Thanks
    • 1
    • 1
  • f

    flat-car-15181

    03/21/2023, 9:40 PM
    Hi.
  • f

    flat-car-15181

    03/21/2023, 9:41 PM
    I have physically downloaded k3d as none of the commands were working for me. However When I try to use the command k3d cluster create -a 2. I receive an error message telling me that k3d is a term that is not reconised
    w
    • 2
    • 1
  • f

    flat-car-15181

    03/21/2023, 9:42 PM
    However my terminal highlits k3d in yellow for me
  • f

    flat-car-15181

    03/21/2023, 9:42 PM
    Is this something someone can help me with?
Powered by Linen
Title
f

flat-car-15181

03/21/2023, 9:42 PM
Is this something someone can help me with?
View count: 2