Category Archives: Scripts

Scripts (actually mini-scripts) in bash, php, python which I hope will save you time

Bash Script to Install WordPress Automatically with WP-CLI

A small bash script to install wordpress with wp-cli I decided to write a small bash script to speed up wordpress installation. This script should work in ubuntu/debian and centos/redhat but with minor changes. I use supervisored, so you need to replace supervisored word from script with what you have (systemctl, etc). In addition I decided to put more ping services (although this slows the site loading speed if you post frequently) for posterity Of course I assume you already have your database with user and pass..

If you encounter problems leave a comment, and we will solve it

Docker containers back-up with shell scripts

Docker containers back-up with some small schell scripts twice per month We’ll be making 2 small shell scripts to backup our containers and insert them in crontab. Theese scripts are for two containers but you can extend them as you please. I have two containers nginx/php-fpm and mariadb. We’ll put our shell script inside /home First is named comnginx.sh and second commmaria.sh

(to see active containers) Here we have 3 containers mariadb and nginx-php-fpm with ids b7b7ad5f1314 and f541404f564f and with names tot9_mariadb and tot9_nginx-php-fpm Now we start our shell scripts:

after we opened the file we place:

ctrl+x and yes to save. Where b7b7ad5f1314 is container […]