#!/bin/bash #################################################################################################### #### author: SlickStack ############################################################################ #### link: https://slickstack.io ################################################################### #### mirror: http://mirrors.slickstack.io/bash/ss-install-adminer.txt ############################## #### path: /var/www/ss-install-adminer ############################################################# #### destination: n/a (not a boilerplate) ########################################################## #### purpose: Reinstalls the entire Adminer module for SlickStack servers (idempotent) ############# #### module version: Adminer 4.7.8 ################################################################# #### sourced by: ss-install ######################################################################## #### bash aliases: ss install adminer ############################################################## #################################################################################################### ## 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-Adminer: 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-adminer: Reinstalls the entire Adminer module for SlickStack servers (idempotent)... ${NOCOLOR}" sleep "$SLEEP_MESSAGE_BEGIN" #################################################################################################### #### SS-Install-Adminer: Cleanup Temporary Files ################################################### #################################################################################################### ## delete tmp files ## rm /tmp/adminer* #################################################################################################### #### SS-Install-Adminer: Install Adminer (phpMyAdmin) Script ####################################### #################################################################################################### ## download latest versions ## wget -O /tmp/adminer.php http://mirrors.slickstack.io/adminer/adminer.txt ## copy files to their destinations ## cp /tmp/adminer.php /var/www/meta/adminer.php ## add script to check Nginx server block for adminer location if not exist run ss-install-nginx ## #################################################################################################### #### SS-Install-Adminer: Reset Permissions (Adminer) ############################################### #################################################################################################### ## run ss-perms-adminer ## source /var/www/ss-perms-adminer #################################################################################################### #### SS-Install-Adminer: Cleanup Temporary Files ################################################### #################################################################################################### ## delete tmp files ## rm /tmp/adminer* #################################################################################################### #### SS-Install-Adminer: 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-adminer #################################################################################################### #### SlickStack: External References Used To Improve This Script (Thanks, Interwebz) ############### #################################################################################################### ## NOTE: do not convert adminer.php to UTF-8 format on GitHub or else it will break ## Ref: https://sourceforge.net/p/adminer/bugs-and-features/630/ ## SS_EOF