- You must have docker installed on your system: macOS Installer (required)
- For a better performance on macOS docker-magento use docker-sync (optional)
--
sudo gem install docker-sync
- Clone the website file repository into your working directory
- Add
dm
to your aliases filealias dm=".dm/bin/dm"
- Clone docker-magento into a
.dm
directory in the Magento rootgit clone git git@github.com:danhort/docker-magento.git .dm
- Initialize the environment with available PHP versions (7.3 or 7.4 or 8.1)
dm --init-sync <PHP version>
ordm --init <PHP version>
- Create the new container
dm start
- Copy files to container (not needed with docker-sync or on linux)
dm copytocontainer --all
- Run composer
dm composer install
- Import your database
dm db-import <absolute path to sql file> (it can be gzipped)
Full list of available options can be found by running: dm --help
Magento: https://magento.localhost
phpMyAdmin: http://localhost:8080
MailHog: http://localhost:8025