#!/bin/bash #################################################################################################### #### author: SlickStack ############################################################################ #### link: https://slickstack.io ################################################################### #### mirror: http://mirrors.slickstack.io/bash/ss-install-php.txt ################################## #### path: /var/www/ss-install-php ################################################################# #### destination: n/a (not a boilerplate) ########################################################## #### purpose: Reinstalls the entire PHP-FPM module for SlickStack servers (idempotent) ############# #### module version: PHP-FPM 7.4.x ################################################################# #### sourced by: ss-install ######################################################################## #################################################################################################### ## SS-CONFIG MUST BE PROPERLY CONFIGURED AND ON CURRENT BUILD BEFORE RUNNING SS-INSTALL ## ## ENSURE YOUR SS-CONFIG BUILD REMAINS CURRENT BY RUNNING SS-UPDATE OCCASIONALLY ## ## include SlickStack configuration ## source /var/www/ss-config ## include SlickStack functions ## source /var/www/ss-functions #################################################################################################### #### SS-Install-PHP: Message (Begin Script) ######################################################## #################################################################################################### ## this is a simple message that announces to the shell the purpose of this bash script ## ## it will only be noticed by sudo users who manually call ss core bash scripts ## ## echo message ## echo -e "${PURPLE}Running ss-install-php: Reinstalls the entire PHP-FPM module for SlickStack servers (idempotent)... ${NOCOLOR}" sleep "$SLEEP_MESSAGE_BEGIN" #################################################################################################### #### SS-Install-PHP: Backup Database Before Proceeding ############################################# #################################################################################################### ## first dump the live database to /meta/ folder for safe-keeping before major changes ## ## this snippet is included in many ss core bash scripts that modify the server ## ## run ss-dump-database ## source /var/www/ss-dump-database #################################################################################################### #### SS-Install-PHP: Install PHP-FPM Packages (Ubuntu) ############################################# #################################################################################################### ## run ss-install-php-core ## source /var/www/ss-install-php-core #################################################################################################### #### SS-Install-PHP: Install (Optimize) PHP-FPM Configuration Files ################################ #################################################################################################### ## run ss-install-php-config ## source /var/www/ss-install-php-config #################################################################################################### #### SS-Install-PHP: Reset Permissions (PHP-FPM) ################################################### #################################################################################################### ## run ss-perms-php ## source /var/www/ss-perms-php #################################################################################################### #### SS-Install-PHP: Touch Timestamp File (End Script) ############################################# #################################################################################################### ## this is a dummy timestamp file that will remember the last time this script was run ## ## it can be useful for developer reference and is sometimes used by SlickStack ## ## script timestamp ## touch /var/www/meta/.timestamp-ss-install-php #################################################################################################### #### SlickStack: External References Used To Improve This Script (Thanks, Interwebz) ############### #################################################################################################### ## Ref: ## SS_EOF