Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
HTTPS_CONF="/etc/apache2/sites-available/$EDITORDOMAIN"
DOMAIN=$(whiptail --title "Techandme.se Collabora" --inputbox "Nextcloud url, make sure it looks like this: cloud\.yourdomain\.com" 10 60 cloud\.yourdomain\.com 3>&1 1>&2 2>&3)
EDITORDOMAIN=$(whiptail --title "Techandme.se Collabora" --inputbox "Collabora subdomain eg: office.yourdomain.com" 10 60 3>&1 1>&2 2>&3)
# Message
whiptail --msgbox "Please before you start make sure port 443 is directly forwarded to this machine or open!" 20 60 2
# Update & upgrade
{
#!/bin/sh
#
# Tech and Me, 2016 - www.techandme.se
# Whiptail menu to install various Nextcloud app and do other useful stuf.
################################################ Variable 1
################################ Network 1.1
IFCONFIG=$(ifconfig)
IP="/sbin/ip"
IFACE=$($IP -o link show | awk '{print $2,$9}' | grep "UP" | cut -d ":" -f 1)
#!/bin/bash
#
# Tech and Me, ©2016 - www.techandme.se
# Variable
IMG='/path'
MNT='/mnt/arm'
# Upgrade and update
apt-get autoclean
#!/bin/bash
ROUTER="192.168.1.1"
IP=$(hostname -I | cut -d ' ' -f 1)
IF="/sbin/ip"
IFACE=$($IF -o link show | awk '{print $2,$9}' | grep "UP" | cut -d ":" -f 1)
DOMAIN="vpn.waaromzomoeilijk.nl"
# Check if root
if [ "$(whoami)" != "root" ]; then
echo

Raspberry Pi VPN Router

This is a quick-and-dirty guide to setting up a Raspberry Pi as a "router on a stick" to PrivateInternetAccess VPN.

Requirements

Install Raspbian Jessie (2015-09-24-raspbian-jessie.img) to your Pi's sdcard.

Use the Raspberry Pi Configuration tool or sudo raspi-config to:

@WaaromZoMoeilijk
WaaromZoMoeilijk / install_spreedme_webrtc.sh
Last active March 23, 2020 21:17
install spreed webrtc server on ubuntu and configure own/nextcloud
#!/bin/sh
#
# Tech and Me, 2016 - www.techandme.se
#
# Secrets
ENCRYPTIONSECRET=$(openssl rand -hex 32)
SESSIONSECRET=$(openssl rand -hex 32)
SERVERTOKEN=$(openssl rand -hex 32)
SHAREDSECRET=$(openssl rand -hex 32)
VirtualBox Setup with Autostart on boot
I wanted to post how I to setup Oracle VirtualBox with VM (Virtual Machine) Autostart, Resolved Screen Resolutions Issues, etc. This is all being done on the Ubuntu 14.04.1 Linux OS.
1. Install Oracle Virtualbox
2. Install Guest Plugins
# Check if the user ncadmin exists, if not create it. This option for installs other then the pre-configured VM
ret=false
getent passwd $UNIXUSER >/dev/null 2>&1 && ret=true
if $ret; then
echo
echo "User $UNIXUSER exists..."
echo
else
adduser --gecos GECOS $UNIXUSER << EOF
$UNIXPASS
#!/bin/sh
IP='techandme.nl'
# Check if root
if [ "$(whoami)" != "root" ]; then
echo
echo -e "\e[31mSorry, you are not root.\n\e[0mYou must type: \e[36msudo \e[0mbash vpnserver2.sh"
echo
exit 1
fi
#!/bin/sh
NAMECRT='Pi.crt'
NAMEKEY='Pi.key'
IP='192.168.1.109'
DNS='8.26.56.26'
IFACE=$(/sbin/ip -o link show | awk '{print $2,$9}' | grep "UP" | cut -d ":" -f 1)
# Check if root
if [ "$(whoami)" != "root" ]; then
echo