This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is an annotated subset of the Nginx configuration from our Magento production platform @ www.hypernode.com | |
# See https://www.byte.nl/blog/magento-cacheleak-issue | |
# !!!! If you are a Hypernode customer, do not use this config as it will result in duplicate statements. !!!!! | |
user app; | |
worker_processes 4; | |
pid /var/run/nginx.pid; | |
events { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt update && sudo apt upgrade -y | |
sudo apt install git python3-pip build-essential wget python3-dev python3-venv python3-wheel libxslt-dev libzip-dev libldap2-dev libsasl2-dev python3-setuptools node-less -y | |
wget https://builds.wkhtmltopdf.org/0.12.1.3/wkhtmltox_0.12.1.3-1~bionic_amd64.deb | |
sudo apt install ./wkhtmltox_0.12.1.3-1~bionic_amd64.deb -y | |
# source go to https://github.com/Yenthe666/InstallScript | |
sudo wget https://raw.githubusercontent.com/Yenthe666/InstallScript/12.0/odoo_install.sh | |
nano odoo_install.sh | |
# Line OE_USER="odoo" is your odoo folder name leave as it is | |
# Line OE_SUPERADMIN="admin" is the master password for this Odoo installation (admin). Change admin to your new strong password |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
UNIFI_DOMAIN="unifi.example.com" | |
WEECHAT_DOMAIN="weechat.example.com" | |
WEECHAT_USER="username" | |
DOMAIN_LIST="$UNIFI_DOMAIN $WEECHAT_DOMAIN www.example.com" | |
######################################################################## | |
# | |
# Program header |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -e | |
clear | |
echo "============================================" | |
echo "WordPress Install Script" | |
echo "============================================" | |
echo "Database Name: " | |
read -e dbname | |
echo "Database User: " | |
read -e dbuser | |
echo "Database Password: " |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
db: | |
image: postgres:10 | |
volumes: | |
- db-data:/var/lib/postgresql/data/pgdata | |
ports: | |
- 5432:5432/tcp | |
environment: | |
- POSTGRES_PASSWORD=odoo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
clear | |
############## | |
# Am I root? # | |
############## | |
if [ "x$(id -u)" != 'x0' ]; then | |
echo 'Error: this script can only be executed by root.' | |
echo 'Try re-run the script after switched to root account by type "sudo su"' | |
exit 1 | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.1' | |
services: | |
postgres: | |
image: postgres | |
container_name: postgres | |
restart: always | |
environment: | |
- POSTGRES_USER=test | |
- POSTGRES_PASSWORD=test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo -v | |
# Setup | |
mkdir tmp | |
cd tmp | |
# Install PDFEdit and dependencies | |
wget http://mirrors.kernel.org/ubuntu/pool/main/l/lcms/liblcms1_1.19.dfsg-1ubuntu3_amd64.deb | |
wget http://mirrors.kernel.org/ubuntu/pool/main/libm/libmng/libmng1_1.0.10-3_amd64.deb | |
wget http://mirrors.kernel.org/ubuntu/pool/main/libp/libpng/libpng12-0_1.2.54-1ubuntu1_amd64.deb |
If you need to move a lot of files between DO server you can move these through SCP over the internal private Digital Ocean network.
NB both droplets need to be within the same region
To do this you need:
- enable private network for each droplet (if not done at creation, note the droplet needs to be off for this to be enabled once live)
- ensure that
eth1
is enabled for both droplets if not already - see https://www.digitalocean.com/community/tutorials/how-to-enable-digitalocean-private-networking-on-existing-droplets - scp files from the source server to the destination server are sent like: