Docker Desktop, Docker Compose and Kubernetes (K8S) on macOS
Docker Desktop is an easy-to-install application for your Mac or Windows environment that enables you to build and share containerized applications and microservices. Docker Desktop includes Docker Engine, Docker CLI client, Docker Compose, Docker Content Trust, Kubernetes, and Credential Helper.
Some of the key features of Docker Desktop include:
Ability to containerize and share any application on any cloud platform, in multiple languages and frameworks
Easy installation and setup of a complete Docker development environment
Includes the latest version of Kubernetes
Automatic updates to keep you up to date and secure
On Windows, the ability to toggle between Linux and Windows Server environments to build applications
Fast and reliable performance with native Windows Hyper-V virtualization
Ability to work natively on Linux through WSL 2 on Windows machines
Volume mounting for code and data, including file change notifications and easy access to running containers on the localhost network
In-container development and debugging with supported IDEs
Install Homebrew (brew).
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
Insall Docker Desktop.
brew install --cask docker
Check Docker and Docker Compose version.
$ docker -v
Docker Desktop includes a standalone Kubernetes server and client, as well as Docker CLI integration that runs on your machine. The Kubernetes server runs locally within your Docker instance, is not configurable, and is a single-node cluster.
The Kubernetes server runs within a Docker container on your local system, and is only for local testing. Enabling Kubernetes allows you to deploy your workloads in parallel, on Kubernetes, Swarm, and as standalone containers. Enabling or disabling the Kubernetes server does not affect your other workloads.
To enable Kubernetes support and install a standalone instance of Kubernetes running as a Docker container, go to
Kubernetes and then click
Apply & Restart to save the settings and then click Install to confirm. This instantiates images required to run the Kubernetes server as containers, and installs the
/usr/local/bin/kubectl command on your machine.
Kubernetes failed to start
Troubleshoot from the menu bar to see the troubleshoot options.
The Troubleshoot page contains the following options:
Restart Docker Desktop: Select to restart Docker Desktop.
Support: Developers on Pro and Team plans can use this option to send a support request. Other users can use this option to diagnose any issues in Docker Desktop. For more information, see Diagnose and feedback and Support.
Reset Kubernetes cluster: Select this option to delete all stacks and Kubernetes resources. For more information, see Kubernetes.
Clean / Purge data: This option resets all Docker data without a reset to factory defaults. Selecting this option results in the loss of existing settings.
Reset to factory defaults: Choose this option to reset all options on Docker Desktop to their initial state, the same as when Docker Desktop was first installed.
Uninstall: Choose this option to remove Docker Desktop from your system.
Pull and tag multiple images.
Remember to replace
pause:3.4.1 with your prefer image and version.