This cluster ready docker-compose infrastructure.
git clone https://github.com/clean-docker/Magento2.git m2-docker &&
cd m2-docker &&
docker-compose up -d ;
docker ps
There is a folder in this project calling ./magento2, this folder is the folder /var/www/html/ inside your container, is the folder that you will work on.
To access in you browser you can use https://localhost ( I recommend change your /etc/hosts ).
docker exec -ti m2docker_apache_1 bash
You can access in this URL https://localhost/magento2/ after installed with this commands below.
composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition magento2
In your terminal out of the container run this command.
mysql -u root -proot -h 0.0.0.0 -P 3300
To know what is the IP to use in the Magento 2 installation (Database Server Host), you can use this command out the container.
docker inspect m2docker_db_1 | grep IPAddress
MIT © 2017 Rafael Corrêa Gomes and contributors.