Skip to content

Environment Setup - Mac

This guide provides step-by-step instructions on how to install Python 3.10 and Docker on your Mac using Homebrew, a popular package manager for macOS.


  • macOS operating system
  • Administrator access to your Mac
  • An internet connection

Step 1: Install Homebrew

Homebrew is a free and open-source package management system that simplifies the installation of software on macOS. If you do not have Homebrew installed on your Mac, follow these steps to install it.

Open the Terminal app. You can find it in the /Applications/Utilities folder or search for it using Spotlight.

Copy and paste the following command into Terminal and press Enter:

/bin/bash -c "$(curl -fsSL"

The script explains what it will do and then pauses before it does it. You may be prompted to enter your password to allow the installation to proceed.

Follow the on-screen instructions to complete the installation of Homebrew.

Once installed, you'll need to add Homebrew to your PATH if the installation script hasn't already done it for you. Add the following line to your .zshrc or .bash_profile file:

echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> /Users/$(whoami)/.zprofile
eval "$(/opt/homebrew/bin/brew shellenv)"

Verify the installation by running:

brew --version

Step 2: Install Python 3.10

Now that Homebrew is installed, you can easily install Python 3.10.

Update Homebrew's package database:

brew update
Install Python 3.10 by running:

brew install python@3.10

After installation, link Python 3.10 if it's not already set as the default version:

brew link python@3.10

Confirm that Python 3.10 is installed correctly:

python3 --version

You should see Python 3.10.x as the output.

Step 3: Install Docker

Docker allows you to package an application with all of its dependencies into a standardized unit for software development.

Update Homebrew's package database (if you haven't already):

brew update

Install Docker using Homebrew by running:

brew install --cask docker

Once installed, you can open Docker from the Applications folder or search for it using Spotlight.

Follow the on-screen instructions to complete the Docker setup.

Step 4: Verify Docker Installation

To verify that Docker has been installed correctly and is running, open Terminal and type:

docker --version

You should see the Docker version displayed, confirming the successful installation.