Install Docker and Docker Compose on Ubuntu

blue and red cargo ship on sea during daytime

Install Docker

apt-get install apt-transport-https ca-certificates software-properties-common -y
curl -fsSL -o && sh

Install Docker Compose

curl -L "$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose

chmod +x /usr/local/bin/docker-compose

ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose

Fail2ban SSH

two bullet surveillance cameras attached on wall
apt-get install fail2ban -y

cd /etc/fail2ban/
vi jail.local


ignoreip =


# SSH servers


enabled = true
filter = sshd
port    = ssh
banaction = iptables-multiport
bantime = 3600
maxretry = 1
logpath = %(sshd_log)s
backend = %(sshd_backend)s
/etc/init.d/fail2ban restart

Done! 🙂

Install Ghost blog on Ubuntu

black and silver computer ram stick

Update and Upgrade installed packages

apt-get update
apt-get upgrade -y

Add user and add user to sudo group

adduser blog
usermod -aG sudo blog

Install Nginx and MySQL

apt-get install nginx -y
ufw allow 'Nginx Full'
apt-get install mysql-server -y

Install Node.js

curl -sL | sudo -E bash
apt-get install -y nodejs

Install Ghost Cli

npm install [email protected] -g

MySQL – User, Database ana access

CREATE USER 'blog'@'localhost' IDENTIFIED BY 'password';
ALTER USER 'blog'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';
GRANT ALL PRIVILEGES ON blog.* TO 'blog'@'localhost';

Install Ghost

su - blog
mkdir blog
cd blog
ghost install