In here is some collection touch point for standardize Magento installation to prepare for subscription packages
<> How to detect OS system
egrep '^(VERSION|NAME)=' /etc/os-release
The output value will be
NAME="CentOS Linux"
VERSION="8 (Core)"
<> How to finding the right PHP for Magestore Product
With Magento lower than 2.4: using PHP 7.2
With Magento from 2.4: using PHP 7.3
Repository can be used for adding the right PHP version is ondrej/php
Ubuntu
sudo apt-get install software-properties-common
sudo add-apt-repository ppa:ondrej/php
sudo apt-get install php(7.2 | 7.3)
CentOS
sudo yum install epel-release yum-utils
sudo yum install http://rpms.remirepo.net/enterprise/remi-release-7.rpm
sudo yum-config-manager --enable (remi-php73 | remi-php72)
Amazon Linux 2
Notice: with this OS, we only have 1 version PHP can be existed. Any update or upgrade that related to PHP should be considered very carefully!
sudo yum update -y
sudo amazon-linux-extras install -y (php7.2 | php7.3)
PHP plugin list
Ubuntu - sudo apt-get install -y php(7.2 | 7.3)-{pdo,mysql,cgi,common,curl,mbstring,gd,bcmath,json,xml,fpm,intl,zip,imap}
CentOS / Amazon Linux 2 - sudo yum install -y php(7.2 | 7.3)-{pdo,mysql,cgi,common,curl,mbstring,gd,bcmath,json,xml,fpm,intl,zip,imap,soap}
<> How to get right Apache 2 for OS
Ubuntu
sudo apt-get install -y apache2
sudo systemctl enable apache2 --> This for automate start apache2 after restarting
CentOS / Amazon Linux 2
sudo yum install -y httpd
sudo systemctl start apache2 --> Apache 2 doesn't start automatically in CentOS
sudo systemctl enable apache2
<> How to get MariaDB (version 10.3)
Ubuntu
sudo apt-get install software-properties-common
wget https://downloads.mariadb.com/MariaDB/mariadb_repo_setup
echo "9f73807c80d14930494021d23abc222c9dd5a1c2731510a2b4d0f835fcc0ae4e mariadb_repo_setup" | sha256sum -c -
chmod +x mariadb_repo_setup
sudo ./mariadb_repo_setup --mariadb-server-version="mariadb-10.3"
sudo apt update
sudo apt-get install -y mariadb-server mariadb-client mariadb-common libmariadb3
CentOS / Amazon Linux 2
$ curl -LsS https://downloads.mariadb.com/MariaDB/mariadb_repo_setup | sudo bash -s -- --mariadb-server-version="mariadb-10.3"
$ sudo yum install -y MariaDB-server MariaDB-client
<> How to get ElasticSearch
Ubuntu
sudo apt-get install -y openjdk-8-jdk
curl -fsSL https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -
echo "deb https://artifacts.elastic.co/packages/7.x/apt stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-7.x.list
sudo apt-get install -y elasticsearch
sudo systemctl start elasticsearch
sudo systemctl enable elasticsearch
CentOS / Amazon Linux 2
$ sudo yum install -y java-1.8.0-openjdk.x86_64 wget
$ wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.9.2-x86_64.rpm
$ sudo rpm -ivh elasticsearch-7.9.2-x86_64.rpm
$ sudo systemctl start elasticsearch
$ sudo systemctl enable elasticsearch
<> Certbot / SSL
Ubuntu
$ sudo add-apt-repository ppa:certbot/certbot
$ sudo apt install -y python-certbot-apache
CentOS / Amazon Linx 2
sudo amazon-linux-extras install epel
sudo yum install -y certbot