Command Line

  1. Create a new admin user in Magento 2 using the CLI

    php bin/magento admin:user:create --admin-firstname=Russell --admin-lastname=Albin --admin-user=ausernamegoeshere --admin-password=somepassword

    Read more »
  2. Search for files that have been updated recently in Linux

    If you are searching for files that have been recently updated you can use the find command

    This example will get all files that were changed within the past 3 days

    find . -ctime -3
    Read more »
  3. rysnc with AWS and using a pem key

    SSH into Amazon using PEM

    Move files from local to Amazon

    rsync-rave "ssh -i some.pem"/path/to/local/files/* ec2-user@EC2_INSTANCE_HOSTNAME:/path/to/remote/file
    Read more »
  4. Changing the Order number and Invoice number starting sequence for Magento 2

    Recently I needed to update a Magento 2 store to start Order numbers and Invoice numbers to specific numbers. Its pretty easy, you just need access to the database and run these commands:

    Read more »
  5. Rackspace Cloud Centos postfix

    When reviewing the /var/log/maillog in my Centos server, I noticed that gmail was not happy with my settings and rejecting emails.

    Our system has detected that 550-5.7.1 this message does not meet IPv6 sending guidelines regarding PTR 550-5.7.1 records and authentication. Please review 550-5.7.1 for more information

    Here is a sample of the maillog

    Read more »
  6. Magento 2 on Ubuntu PHP 7 modules needed for Enterprise Edition

    Here is a list of php 7 modules needed to install Magento 2 Enterprise Edition

    Read more »
  7. Magento 2 New Website setup using CLI

    When creating a new website, using the GUI is not always preferred.  In fact, using the CLI or command line interface is much faster.

    After you log into your server and go to the document root of the Magento installation run this command:

    Read more »
  8. New Relic showing errors of missing update/vendor/autoload.php

    You may have a new installation of Magento 2. 

    Without server monitoring, this probably would of gone un-noticed as its failing silently.

    I guess, I could of found it looking at the server logs, but since I was not having any issues, I had no reason to look at them.

    Read more »
  9. Deploying a custom theme to Magento 2

    There are many tutorials that describe how to create a custom theme in Magento 2, so for this I will just outline a few things to look out for when you do.

    If you commit your code and are ready to use it, you need to do a few things to get the Magento 2 ready to use the new theme.

    You need to remove some of the cached files in var/view_preprocessed and var/cache first, the easiest way is to just rm them

    # rm -rf var/view_preprocessed/* var/cache/*  but there is a method that Magento gives us but it seems unreliable.  

    # php bin/magento module:enable Some_Module --clear-static-content  

    Read more »
  10. Magento 2 CLI commands that are used frequently

    Here is a list of CLI commands that are used frequently

    Magento 2 CLI helpful commands

    To get a list of all commands
    php bin/magento
    Read more »
Russell Albin - Omaha, Nebraska Magento Developer Magento Developer Plus Magento Solutions Specialist Magento Front End Developer