Skip to content

Instantly share code, notes, and snippets.

@nileshtrivedi
nileshtrivedi / home-server.md
Last active June 1, 2024 00:11
Home Server setup: Raspberry PI on Internet via reverse SSH tunnel

Raspberry Pi on Internet via reverse SSH tunnel

HackerNews discussed this with many alternative solutions: https://news.ycombinator.com/item?id=24893615

I already have my own domain name: mydomain.com. I wanted to be able to run some webapps on my Raspberry Pi 4B running perpetually at home in headless mode (just needs 5W power and wireless internet). I wanted to be able to access these apps from public Internet. Dynamic DNS wasn't an option because my ISP blocks all incoming traffic. ngrok would work but the free plan is too restrictive.

I bought a cheap 2GB RAM, 20GB disk VM + a 25GB volume on Hetzner for about 4 EUR/month. Hetzner gave me a static IP for it. I haven't purchased a floating IP yet.

@dextersiah
dextersiah / ConnectionV2.py
Created January 28, 2020 09:41
An updated version of GPS Tracking for both python 2 and 3.7 that was created by shiyazt
# This code is only workable on python 2
import httplib, urllib
import time
from GPS_API import *
import serial
ser = serial.Serial("/dev/serial0") # Select your Serial Port
ser.baudrate = 9600 # Baud rate
ser.timeout = 0.5
@superbob
superbob / ddns_provider.conf
Last active January 27, 2024 00:57
Namecheap Synology DSM DDNS provider
#Insert this at the end of /etc.defaults/ddns_provider.conf
[Namecheap]
modulepath=/usr/syno/bin/ddns/namecheap.php
queryurl=https://dynamicdns.park-your-domain.com/update
@patrakov
patrakov / README
Last active October 22, 2023 12:33
Automatically reinstall OpenWRT packages after firmware upgrades
The script helps you restore all installed OpenWRT packages after upgrading the main firmware image via sysupgrade. It works
ONLY if the default firmware image provided by the OpenWRT project is sufficient to get connected to the Internet, but you
want some extra packages for additional functionality. In other words, it WILL NOT WORK if connecting to the Internet
requires installing extra packages (e.g., a kernel module for your LTE modem).
The script has been tested for upgrading from OpenWRT 18.06.1 to 18.06.2 and to a development snapshot, as well as between
development snapshots. On LEDE 17.01.x, "flock" is not a part of the default image, so has to be installed manually.
Initial setup: