Created
August 29, 2019 17:41
-
-
Save damozhang/154542d2d45d98de000d7796e944c9d7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apt upgrade -y | |
apt update -y | |
apt install nginx -y | |
apt install php7.2-fpm php7.2-gd php7.2-gmp php7.2-mysql php7.2-pgsql php7.2-bcmath php7.2-curl php7.2-dom php7.2-mbstring php7.2-bz2 php7.2-zip php-redis libmcrypt-dev php-pear php-dev -y | |
pecl channel-update pecl.php.net | |
pecl install mcrypt-1.0.2 | |
touch /etc/php/7.2/fpm/conf.d/20-mcrypt.ini | |
echo 'extension=mcrypt.so'> /etc/php/7.2/fpm/conf.d/20-mcrypt.ini | |
# Install Composer | |
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" | |
php -r "if (hash_file('sha384', 'composer-setup.php') === 'a5c698ffe4b8e849a443b120cd5ba38043260d5c4023dbf93e1558871f1f07f58274fc6f4c93bcfd858c6bd0775cd8d1') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" | |
php composer-setup.php | |
php -r "unlink('composer-setup.php');" | |
mv composer.phar /usr/local/bin/composer |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment