Spinning container lab in gitlab runner not working #2010
-
Hi, I am trying to deploy clab in Kubernetes gitlab runner. I am finding this issue when I run clab dep -t command
|
Beta Was this translation helpful? Give feedback.
Replies: 6 comments
-
Hi @priyacshah,
|
Beta Was this translation helpful? Give feedback.
-
Thanks for the response. Attaching the snapshot of docker logs. |
Beta Was this translation helpful? Give feedback.
-
@priyacshah this is related to the way your runner is set up and it seems containerlab can't do much... Given you have permission issues as per your screenshot I suggest you try to figure out how to run privileged containers in your runner |
Beta Was this translation helpful? Give feedback.
-
Made some progress but now it showing me this error
Here is my config.toml file
|
Beta Was this translation helpful? Give feedback.
-
I don't think clab will work with a gitlab's docker runner with that config. This is because you mount the docker socket to the runner' container, but you don't mount the network namespace, hence the container gets created outside of the runner's netns but tries to lookup the docker bridge in the runner's namespace. What could work is using a docker image that has docker installed inside. |
Beta Was this translation helpful? Give feedback.
-
Thanks. I installed the docker inside the docker image. Finally able to deploy clab in gitlab runner docker executor with the below config. There was a mounting issue for which I added volume & network_mode = "host" to resolve above issue. But I am getting this warning for which I am not sure how to resolve yet: Waiting for services to be up and running (timeout 30 seconds)... config.toml:
|
Beta Was this translation helpful? Give feedback.
Thanks. I installed the docker inside the docker image. Finally able to deploy clab in gitlab runner docker executor with the below config. There was a mounting issue for which I added volume & network_mode = "host" to resolve above issue. But I am getting this warning for which I am not sure how to resolve yet:
Waiting for services to be up and running (timeout 30 seconds)...
*** WARNING: Service runner-fendbp3-project-66846-concurrent-0-b5fd77b78e08c810-docker-0 probably didn't start properly.
Health check error:
create service container: Error response from daemon: conflicting options: host type networking can't be used with links. This would result in undefined behavior (services.go:2…