WordPress Backup Script Rumi, August 23, 2020 #!/bin/bash # This script creates a compressed backup archive of the given directory and the given MySQL table. More details on implementation here: https://theme.fm # Feel free to use this script wherever you want, however you want. We produce open source, GPLv2 licensed stuff. # Author: Konstantin Kovshenin exclusively for Theme.fm in June, 2011 # Modification by Hasan T. Emdad tweenpath.net on August, 2020 # Set the date format, filename and the directories where your backup files will be placed and which directory will be archived. NOW=$(date +"%Y-%m-%d-%H%M") FILE="example.org.$NOW.tar" BACKUP_DIR="/backups" WWW_DIR="/var/www/example.org/" # MySQL database credentials DB_USER="mysqluser" DB_PASS="mysqlpass" DB_NAME="example_org" DB_FILE="example.org.$NOW.sql" # Tar transforms for better archive structure. WWW_TRANSFORM='s,^var/www/example.org,www,' DB_TRANSFORM='s,^var/www/example.org/backups,database,' # Create the archive and the MySQL dump tar -cvf $BACKUP_DIR/$FILE --transform $WWW_TRANSFORM $WWW_DIR mysqldump --user=${DB_USER} --password=${DB_PASS} $DB_NAME > $BACKUP_DIR/$DB_FILE # Append the dump to the archive, remove the dump and compress the whole archive. tar --append --file=$BACKUP_DIR/$FILE --transform $DB_TRANSFORM $BACKUP_DIR/$DB_FILE rm $BACKUP_DIR/$DB_FILE gzip -9 $BACKUP_DIR/$FILE Related Scripts Wordpress
Zimbra Let’s Encrypt SSL Script December 28, 2022 #!/bin/bash -x # SSL certificate installation in Zimbra # with SSL certificate provided by Let’s Encrypt (letsencrypt.org) # Check if running as root if [ “$(id -u)” != “0” ]; then echo “This script must be run as root” 1>&2 exit 1 fi read -p ‘letsencrypt_email [mail@server]: ‘ letsencrypt_email read… Read More
PHP enable error reporting December 11, 2013 You can set PHP error reporting on in php.ini file (in case you have access to this file). Set the following lines: error_reporting = E_ALL display_errors = On If you have no access to php.ini file but you can modify .htaccess file on your server (in root of your public_hml… Read More
Installer for jitsi-meet, jigasi and jibri November 19, 2022 Found this lovely code base (that actually worked) on github, supported on a debian 10/11 or ubuntu 20+ versions- The script (jitsi_setup.sh) can be used to install stable version of all 3 on a stand-alone server. This is simply a script version of quick-install document at https://jitsi.github.io/handbook/docs/devops-guide/devops-guide-quickstart It Installs below… Read More