Category: Setup

Install OpenJDK on MacOS

$ brew tap adoptopenjdk/openjdk $ brew search jdk $ brew install –cask adoptopenjdk11

Install L2TP over IPSec on Ubuntu

1. Installation $ sudo apt-get update $ sudo apt-get -y install strongswan xl2tpd 2. Configuration $ sudo vi /etc/ipsec.conf ## == ## config setup conn %default ikelifetime=60m keylife=20m rekeymargin=3m keyingtries=1 keyexchange=ikev1 authby=secret ike=aes128-sha1-modp1024,3des-sha1-modp1024! esp=aes128-sha1-modp1024,3des-sha1-modp1024! conn L2TP-PSK keyexchange=ikev1 left=%defaultroute auto=add authby=secret type=transport leftprotoport=17/1701 rightprotoport=17/1701 # set this to the ip address of your vpn server right=[VPN […]

Install Mail Server (iRedMail)

# Tested on Ubuntu 20.04 1. Configure Hostname $ hostnamectl set-hostname mail.example.com $ vi /etc/hosts 127.0.0.1 mail.example.com mail 2. Download iRedMail package $ wget https://github.com/iredmail/iRedMail/archive/1.4.0.tar.gz 3. Install iRedMail on Ubuntu $ tar xvfz 1.4.0.tar.gz $ cd iRedMail-1.4.0 $ chmod +x iRedMail.sh $ sudo ./iRedMail.sh [ Welcome and thanks for your use ] -> [ Default […]

Install No-IP Client (DDNS service)

$ sudo apt-get update $ sudo apt-get -y install build-essential $ cd /usr/local/src/ $ sudo wget http://www.noip.com/client/linux/noip-duc-linux.tar.gz $ sudo tar xvfz noip-duc-linux.tar.gz $ cd noip-{xxxx} $ sudo make install < enter the login information and link this host with a specific domain name > $ sudo vi /etc/systemd/system/noip2.service [Unit] Description=No-Ip Dynamic DNS Update Service After=network.target […]

Install PackStack in CentOS

https://www.rdoproject.org/install/packstack

Install SVN server

$ sudo apt-get install -y subversion apache2 libapache2-svn apache2-utils $ sudo mkdir -p /svn/repo 1. Create a new repository $ sudo svnadmin create /svn/repo/[repo name] $ sudo vi /etc/apache2/sites-available/[repo name].conf ## == ## DAV svn SVNParentPath /svn/repo/ AuthType Basic AuthName “Repo name” AuthUserFile /etc/svnpasswd Require valid-user ## == ## $ sudo a2ensite [repo name] $ […]

Set up Gateway-to-Gateway VPN

1. Create a VPN setup script ## == ## #!/bin/bash # https://wiki.debian.org/IPsec if [ “$#” -ne 5 ]; then echo “Usage: $0 [local public ip] [local virtual ip] [remote public ip] [remote virtual ip]” exit 1 fi echo “install packages…” sudo apt-get install -y ipsec-tools racoon calc_mask () { local ip=$1 var=$(echo $ip | awk […]

Configure NAT and Install DHCP server

1. Network setup $ sudo vi /etc/network/interfaces ## == ## auto lo iface lo net loopback auto eth0 # External network iface eth0 inet dhcp auto eth1 # Internal network iface eth1 inet static address 192.168.0.1 network 192.168.0.0 netmask 255.255.255.0 broadcast 192.168.0.255 ## == ## $ sudo /etc/init.d/networking restart 2. Masquerade setup $ sudo vi /etc/sysctl.conf uncomment […]

Install OwnCloud server

$ sudo apt-get -y install lamp-server^ $ sudo apt-get -y install php5-gd php-xml-parser php5-intl smbclient curl libcurl3 php5-curl $ sudo a2enmod rewrite $ sudo a2enmod headers $ sudo vi /etc/apache2/sites-default # AllowOverride None -> AllowOverride All $ sudo service apache2 restart $ wget http://download.owncloud.org/community/owncloud-latest.tar.bz2 $ sudo tar -xjf owncloud-latest.tar.bz2 -C /var/www/html $ cd /var/www/html $ sudo chown […]

Install Apache + PHP + MySQL

$ sudo apt-get install -y lamp-server^