Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- # Script for Upgrade GCC to Version 7.3, Install Composer, and Upgrade PHP to Version 8.2
- # For CentOS 7.9
- # ENL and ESJ for ever and ever...
- yum install -y wget bzip2 gcc gcc-c++
- cd /tmp
- wget http://ftp.mirrorservice.org/sites/sourceware.org/pub/gcc/releases/gcc-7.3.0/gcc-7.3.0.tar.gz
- tar zxf gcc-7.3.0.tar.gz
- cd gcc-7.3.0
- ./contrib/download_prerequisites
- ./configure --disable-multilib --enable-languages=c,c++
- make -j 4
- make install
- gcc --version
- cd /tmp
- rm -rf gcc-7.3.0.tar.gz
- cd ~
- sudo yum -y install http://rpms.remirepo.net/enterprise/remi-release-7.rpm
- yum install yum-utils
- sudo yum-config-manager --enable remi-php82
- sudo yum -y install httpd mod_ssl postfix dovecot dovecot-mysql php php-fpm php-mysql php-opcache php-xml php-xmlrpc php-imap php-mbstring php-common php-gd php-json php-cli php-pdo php-zip wget unzip 7zip -y
- php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
- HASH="$(wget -q -O - https://composer.github.io/installer.sig)"
- php -r "if (hash_file('SHA384', 'composer-setup.php') === '$HASH') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
- sudo php composer-setup.php --install-dir=/usr/local/bin --filename=composer
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement