Skip to content

Install Extension

How to Install

Even though Magento platform has built-in functionality, to provide your business needs, you can also use its additional features (extension).

In this article, we will explain in detail how to install the Magento 2 extensions. We will use the ProfStep_Quotation module for the example purpose.

There are several different solutions:

As a ZIP package

This section discusses the way to download a ProfStep extension as a ZIP-package.

Customer Area

Once you purchase the extension, it will be listed in the Products section in the customer area:

Products Section ProfStep purchased Packages list

Find an appropriate extension in the list and click on the “Download” button to install the package you need

Package structure

The installed ZIP-package will contain the following files structure:

  • Directoryapp
    • Directorycode
      • DirectoryProfStep
        • DirectoryCore/
        • DirectoryQuotation/

Installation

When all the necessary packages have been downloaded, follow these steps depending on your OS to deploy modules:

Windows OS

| In case of Windows OS, you need to use FTP/SFTP Clients. We recommend such clients as FileZilla or WinSCP.

| For this purpose, we will use WinSCP client.

  1. |   Connect to the server where your Magento source folder is located with FTP or SFTP Clients. |   Open it and enter the server’s credentials and click on the Login button.

    Alternative text

  2. Open Magento source folder by clicking on the server folder path.

    Alternative text

  3. Move the installed packages (in our example it’s ProfStep_Core and [ProfStep_Quotation] modules) to the app/code/ folder as shown below:

    Alternative text

  4. After the previous step, open WinSCP Command Line

    Alternative text

  5. Now, please, run the following commands in the Magento 2 root folder:

    Terminal window
    php bin/magento mod:en ProfStep_Core ProfStep_Quotation # To enable modules
    php bin/magento setup:upgrade # Upgrade database schema.
    php bin/magento setup:di:compile # Start application code generation
    php bin/magento setup:static-content:deploy # Generate static content
Linux distribution

In the Linux/Unix systems the Secure Shell (SSH) protocol can be used, for securing and copying files and directories remotely.

  1. We will use the rsync command. Specify the archive name with modules as the first argument and second argument in the next format user_name@host

    • user_name - the account name that is being accessed on the host.

    • host - it can be a server IP address (e.g. 192.168.1.22) or domain name (e.g. test.domain). Also after : path for copying can be specified.

      Terminal window
      rsync Archive.zip user_name@host:/var/www/magento2-folder

    Alternative text

    Then the server requires a password.

  2. Login to the server via ssh. Specify only the user_name@host as the first argument (like in rsync)

    Terminal window
    ssh user_name@host

    Alternative text

  3. After that we need to execute several commands to the ZIP-archive with modules to the Magento root folder.

    Terminal window
    cd /var/www/magento2-folder # Change directory to the Magento 2 root folder
    ls -la | grep Archive.zip # Verify if the archive with modules has been copied
    sudo mv Archive.zip app/code/ # Move archive to the app/code/ folder
    cd app/code/ # Change directory to the app/code/
    unzip ProfStep # Extract modules from the archive
    ls -la ProfStep # To display a list of modules

    Alternative text

  4. Now, please run the following commands in the Magento 2 root folder:

    Terminal window
    php bin/magento mod:en ProfStep_Core ProfStep_Quotation # To enable modules
    php bin/magento setup:upgrade # Upgrade database schema.
    php bin/magento setup:di:compile # Start application code generation
    php bin/magento setup:static-content:deploy # Generate static content
MacOS

MacOS is unix-based OS (more specifically free-BSD). So we can use SSH also.

  1. Firstly, we need to copy a ZIP-archieve to our server. For this purpose can be used rsync command.

    Terminal window
    rsync Archive.zip user_name@host:/var/www/magento2-folder

    Where

    • user_name - the account name that is being accessed on the host.
    • host - it can be an server IP address (e.g. 197.154.1.22) or domain name (e.g. test.domain). Also after : path for copying can be specified.

    Alternative text

  2. Login to server via ssh. Specify user_name@host (like rsync).

    Terminal window
    ssh user_name@host

    Alternative text

  3. When you successfully logged in to server, execute several commands in Magento 2 root folder:

    Terminal window
    cd /var/www/installation-demo/ # Change directory to Magento 2 root folder
    sudo mv ProfStep.zip app/code/ # Move archive to app/code/ folder
    cd app/code/ # Change directory to app/code/
    unzip ProfStep.zip # Extract modules from archive
    ls -la | grep ProfStep # To display a list of modules

    Alternative text

  4. To enable module, please, run the following commands in Magento 2 root folder:

    Terminal window
    php bin/magento mod:en ProfStep_Core ProfStep_Quotation # To enable modules
    php bin/magento setup:upgrade # Upgrade database schema.
    php bin/magento setup:di:compile # Start application code generation
    php bin/magento setup:static-content:deploy # Generate static content

Magento uses Composer to manage components and their dependencies. Using Composer you can easily download our modules.

Open CLI, then run these commands in the Magento 2 root folder:

  1. Connect to your server. You can use WinSCP or SSH guides (they’re located above)

  2. Add ProfStep composer repository by the following command:

    Terminal window
    composer config repositories.profstep composer https://repo.profstep.com/
  3. Please run the following commands in the server console to deploy a new extension:

    Terminal window
    composer require profstep/module-quotation # Add this package to the composer.json
    php bin/magento mod:en ProfStep_Core ProfStep_Quotation # To enable modules
    php bin/magento setup:upgrade # Upgrade database schema.
    php bin/magento setup:di:compile # Start application code generation
    php bin/magento setup:static-content:deploy # Generate static content

    When the first command has been executed, you may get the following message:

    Alternative text

    Specify your public key as username and private key as a password.

Install the ProfStep_Core module

Via Composer

Run the following commands in the Magento 2 root:

Terminal window
composer require profstep/module-core
php bin/magento mod:en ProfStep_Core # To enable Core module
php bin/magento setup:upgrade # Upgrade database schema.
php bin/magento setup:di:compile # Start application code generation