docker build -t devops-toolkit .
minikube start
- Create a docker container: >kubectl apply -f docker.yaml
- command to wait untill pod is ready: >kubectl wait --for condition=containersready pod docker
- Open a shell on the docker container:
apk add -U git git clone https://github.com/ezzat223/kaniko-demo.git (Don't use SSH) cd kaniko-demo/ docker build -t devops-toolkit . - It will generate this error
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
- Finally delete the container.
- The Docker socket
(/var/run/docker.sock)
is a Unix socket file that the Docker daemon listens on. It allows processes to communicate with theDocker daemon
to manage containers, images, networks, etc.
- is the core service behind Docker.
- It’s a server that runs in the background on the host machine, managing Docker containers, images, networks, and volumes.
- It listens to Docker API requests (either from docker CLI commands or external programs) and handles the lifecycle of containers.
- The Docker Daemon uses a
client-server architecture
.
Client
: This is thedocker command-line interface (CLI)
or a program that sends requests to the daemon.Server
: This is thedockerd
process, which listens to these API requests and processes them.
- Once the container is
ready to start
, the Docker Daemon hands off control to the Docker Runtime. - The runtime interacts directly with the kernel to launch and run the container using cgroups (for resource limits) and namespaces (for isolation).
- The runtime then ensures the container continues running as expected and interacts with the kernel-level container features.
kubectl apply -f docker-socket.yml
- Open a shell on the docker container:
apk add -U git git clone https://github.com/ezzat223/kaniko-demo.git (Don't use SSH) cd kaniko-demo/ docker build -t devops-toolkit .
- It worked!
- Finally delete the container.
- Make changes to kaniko-git.yaml by adding your GitHub and Dockerhub users instead.
git add . git commit -m "Changed registry info in kaniko-git.yaml" git push origin master