How to install Docker on your Mac and configure it for SQL Server.
Docker Download Mac
Join Arthur Ulfeldt for an in-depth discussion in this video, Install Docker on Mac, part of Learning Docker. Can I use docker for installing ubuntu on a Mac? One thing to note, though: Both Vagrant and Docker-Machine (or Docker for Mac) run a virtual machine (VirtualBox in most cases) that will block some of the host system's resources. Depending on how you scale that VM, you will see an impact on your host system's performance. If you are using a Mac or have Windows 10 Professional installed on your laptop, then we strongly recommend that you install Docker for Mac or Docker for Windows. These tools give you the best experience when working with containers. Note, older versions of Windows or Windows 10 Home edition cannot run Docker for Windows.
![For For](/uploads/1/3/4/1/134153674/788208921.jpg)
Before you install SQL Server on a Mac, you need to install Docker. This is because the Mac installs (and runs) SQL Server from a Docker container image.
Below are instructions for downloading and installing Docker (it's pretty simple), then configuring it for SQL Server. By 'configuring' I simply mean that you need to allocate enough memory to Docker so that SQL Server can run.
Download Docker
Go to the Docker Community Edition for Mac download page and click Get Docker.Install Docker
Double-click on the downloaded .dmg file and then drag the Docker.app icon to your Application folder.Launch Docker
Launch Docker the same way you'd launch any other application (via Launchpad, the Applications folder, etc).When you first Launch Docker, you might be prompted for your password. Go ahead and provide your password — Docker needs this in order to install its networking components and links to the Docker apps.Increase the Memory
SQL Server needs at least 3.25GB to run, but Docker only allocates 2GB by default. Therefore you should increase this allocation to allow SQL Server to run. Increase it to 4GB (to be on the safe side).To do this:- Select Preferences from the little Docker icon in the top menu
- Select Advanced (if it's not already selected)
- Slide the memory slider up to 4GB
- Click Apply & Restart
Now you can Install SQL Server
Now that you've installed Docker and increased its memory allocation, you can go ahead and install SQL Server on your Mac.
What Exactly is Docker?
Docker is a platform that enables software to run in its own isolated environment. It achieves this through the use of 'containers'.
As explained on the Docker website:
A container image is a lightweight, stand-alone, executable package of a piece of software that includes everything needed to run it: code, runtime, system tools, system libraries, settings.
The main benefit of Docker containers is that they enable us to run software across different computer systems without encountering configuration issues. Because the software is running in its own isolated environment, all configuration settings are already included in the container.
Docker is a popular option for development environments, where software can be developed and tested without having to worry about whether all computers are configured the same. Containers isolate software from its surroundings, for example differences between development and staging environments and help reduce conflicts between teams running different software on the same infrastructure.
Install Docker For Mac Download
But as we can see with SQL Server, Docker can also be used to download and run software on a platform that wouldn't normally be able to run that software (such as running SQL Server on a Mac or Linux).
Why do we need to use Docker to run SQL Server?
Prior to its 2017 release, SQL Server wasn't available for the Mac. The only way you could run SQL Server on a Mac was to use a virtual machine such as VirtualBox, Parallels Desktop, VMware Fusion, or Bootcamp running the Windows operating system. To do this, you had to create the virtual machine, purchase Windows and install it onto that virtual machine, and then finally install SQL Server.
While this is still a viable option today, SQL Server 2017 has provided you with new option: Install SQL Server via Docker — without needing to purchase Windows. The Docker container image contains everything needed to run SQL Server.
Intel System Studio on macOS has been tested with and supports the free 'Community Edition' (CE) version of Docker for Mac. If you have a version of Docker Toolbox for Mac on your system, review this Docker for Mac vs. Docker Toolbox article for upgrade details.
IMPORTANT: Using Intel System Studio with Docker Toolbox for Mac has not been tested and is not a supported configuration.
Prerequisites
Before installing Docker onto your system, make sure the following prerequisites have been met:
- macOS 10.11 (El Capitan) is the recommended minimum version for Docker for Mac, although macOS 10.10.3 (Yosemite) or later will also meet the requirements. Additional Docker for Mac requirements can be found in the Docker online documentation.
- Docker for Mac requires that your development system's CPU include support for the full range of hardware virtualization available in most modern mobile, desktop, and server CPUs. On an Intel processor, this means your CPU supports VT-x, VT-d, and VT-x with EPT (all three virtualization features must be supported). You can determine if your Intel CPU supports these features by visiting ark.intel.com and searching for the processor present in your development system. On AMD* processors, the necessary virtualization features are known generally as AMD-V.
To determine if virtualization is enabled on your Mac, run the following command at a terminal window (shell prompt):
If virtualization is enabled and available on your Mac, you will see the output shown above. If virtualization is unsupported or disabled, you will see the following:
If you believe your Mac has the appropriate CPU to support the virtualization required by Docker for Mac but the virtualization test above returns a zero, see If VT-x virtualization technology is locked or disabled on your Mac.
Install Docker For Mac Command Line
For more complete information about compiler optimizations, see our Optimization Notice.