Phone: +49 30 4373 3797

How to install Magento 2 on MGT Development Environment

October 4, 2016 - Stefan Wieczorek # magento 2, magento2 with composer, mgt development environment

Introduction

In this tutorial we show you how to install Magento 2 with composer on the MGT Developer Environment.

Magento 2 Installation - Preparations

Before we can start with the Magento 2 installation on MGT Development Environment we need to do some prepparations.

1) Install Docker and run the MGT Development Envionment

2) Open the Control Panel under http://127.0.0.1:3333 and add domain e.g. magento2.dev with Magento 2 Vhost Template.

Add Domain

3) Create a database for Magento 2

Go to Databases in the left menu and create a database called magento2

Add database

4) Create a local hosts file entry

In order to resolve the domain magento2.dev we need to add a hosts file entry.

If you don't know how to add an entry you can read the following site in our documentation:

https://www.mgt-commerce.com/documentation/mgt-development-environment-usage-host-file

magento2 hosts file

As you can see in the screenshot above, we have added the following line to our hosts file:

127.0.0.1 magento2.dev

Start installing Magento 2 with composer

1) Login into your container with SSH

ssh root@127.0.0.1
Password: root

2) Go to directory /home/cloudpanel/htdocs/ and run the following composer command

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition  magento2.dev

Composer Commandline

For the installation of magento 2 with composer you need a public and private key, more information can be found at:

http://devdocs.magento.com/guides/v2.0/install-gde/prereq/connect-auth.html


Username = Public Key

Password = Private Key

3) Open http://magento2.dev/ in your browser and follow the magento 2 installation wizard