Skip to content

Instantly share code, notes, and snippets.

@casualjim
casualjim / OVH IPv6 Ubuntu.md
Last active January 21, 2023 20:03
Actually working IPv6 dedicated server configuration for ubuntu

Configure IPv6 on Ubuntu 20.04 on OVH dedicated

Contrary to the guide, do this instead

the gateway is in the /56 network but so you have to get your ip in there.

Edit: /etc/netplan/50-cloud-init.yaml

# This file is generated from information provided by the datasource. Changes
@tannerdsilva
tannerdsilva / hostXMRNode.md
Last active June 11, 2024 09:39
How To Build And Host a Monero Node from Source

How to Build and Install a Monero Node on a Debian-based System

Hello. In this document, we will walk through the steps of building and hosting your own Monero node from source on a Debian-based Linux system. These systems include Raspbian, Debian (9 and above), and Ubuntu (18.04 and above). This tutorial assumes that you are capable of accessing the ROOT terminal of your Debian-based system, and are capable of getting your system online if necessary. You may plan on using an external storage device to store the blockchain, this tutorial will include the optional steps to support external storage. Alternatively, this setup procedure can also accomodate users looking to host a pruned blockchain with restricted storage space.

Here are some useful links for reaching this prerequisite if you do not currently have access to a Debian-based system that meets the recommended system requirements.

@lightmaster
lightmaster / mp4tomkv.sh
Created December 10, 2020 23:47
Find all .mp4 files in the current directory and subdirectories and convert them into .mkv files without re-encoding. This does not lose any quality and the resulting files are the same size as the originals. This will also repair any .mp4 files which do not have `ctts atom`, which can cause playback issues in numerous players. It will delete it…
#!/bin/bash
if ! [ -x "$(command -v mkvmerge)" ]; then
echo 'Error: mkvmerge is not installed.' >&2
exit 1
fi
if ! [ -x "$(command -v ffmpeg)" ]; then
echo 'Error: ffmpeg is not installed.' >&2
exit 1
@daniilyar
daniilyar / BOINC_Rosetta_home_Ubuntu_18
Last active September 28, 2021 10:33
How to install BOINC and start calculating for Rosetta@home (Ubuntu 18)
# Before you start: register at Rosetta website (http://boinc.bakerlab.org/rosetta/join.php) and remember your registration email and password
sudo -i
# install dependencies:
apt -qqy update && apt install -y --auto-remove libsm6 libxext6 libnotify-bin libcurl3 && apt -qqy clean
# Install BOINC:
cd /opt
wget -q https://boinc.berkeley.edu/dl/boinc_7.4.22_x86_64-pc-linux-gnu.sh -O boinc.sh
@nfvs
nfvs / autossh-socks5-proxy.sh
Last active August 3, 2024 18:48
Use autossh to setup a local socks5 proxy
[Unit]
Description=AutoSSH socks5 tunnel
After=network-online.target ssh.service
[Service]
Environment="AUTOSSH_GATETIME=0"
ExecStart=/usr/bin/autossh -M 0 -N -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -i /root/.ssh/id_rsa -D 0.0.0.0:1080 [email protected]
ExecStop=/bin/kill $MAINPID
[Install]
@sanderfoobar
sanderfoobar / rpc_bandwidth.md
Last active June 30, 2019 14:58
Monero RPC node bandwidth monitoring

In this document, $YOUR_IP refers to your public ip address.

Keeping track of bandwidth for Monero RPC nodes

First, we must make a clear distinction between RPC traffic and P2P traffic. As a node operator you might think "wow my node is doing so much traffic WTF where are all these bytes coming from and going to". Well, this is actually due to your P2P port being exposed, which is port 18080. This document does not cover the monitoring of P2P traffic. This document is specifically for the RPC port which runs on 18081 (or 18089).

As Monero RPC traffic is HTTP, we can use nginx to reverse proxy and record bandwidth passing through. This implies that monerod's RPC port stays on localhost

Where normally we would use:

@simeonlg
simeonlg / bookmarklet
Last active September 26, 2018 23:08
Pokemongomap.info scraper for pidgey bot
javascript:var markerList = markerList || {}; for (marker in markers) { if (!markerList.hasOwnProperty(markers[marker].options.locmarkerid)) { console.log("Marker added"); markerList[marker] = '"' + markers[marker].options.title.split(': ')[1] + '","' + markers[marker].options.title.split(': ', 2)[0] + '",' + markers[marker]._latlng.lat.toFixed(6) + ',' + markers[marker]._latlng.lng.toFixed(6); } } var markerString = ""; for (marker in markerList) { markerString += "[" + markerList[marker] + "],"; } (function (text) { var node = document.createElement('textarea'); var selection = document.getSelection(); node.textContent = "[" + text + "]"; document.body.appendChild(node); selection.removeAllRanges(); node.select(); document.execCommand('copy'); selection.removeAllRanges(); document.body.removeChild(node); })(markerString);
@ptrcnull
ptrcnull / bookmarklet
Created August 8, 2018 23:37
pokemongomap.info scrapper
javascript:(function()%7Bvar%20l%3DObject.values(markers).map(m%3D%3E%60%24%7Bm.options.locmarkername%7D%20-%20%24%7Bm._latlng.lat.toFixed(5)%7D%2C%24%7Bm._latlng.lng.toFixed(5)%7D%60).join('%5Cn')%3Bvar%20e%3Ddocument.createEvent('MouseEvents')%3Be.initMouseEvent('click'%2Ctrue%2Cfalse%2Cself%2C0%2C0%2C0%2C0%2C0%2Cfalse%2Cfalse%2Cfalse%2Cfalse%2C0%2Cnull)%3Bvar%20a%3Ddocument.createElement('a')%3Ba.download%3D'locations.txt'%3Ba.href%3D'data%3Atext%2Fplain%3Bcharset%3Dutf-8%2C'%2BencodeURIComponent(l)%3Ba.dispatchEvent(e)%7D)()
@danielsguima
danielsguima / gymhuntr-export.js
Last active August 8, 2018 19:41 — forked from Err0r404/gymhuntr-export.js
Export gym JSON from GymHuntr as Meowth's format
// ==UserScript==
// @name Export visible gym from GymHuntr as Meowth's gym matching JSON format
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Export gyms to json/csv
// @author danielsguima
// @match https://gymhuntr.com/
// @grant none
// @downloadURL https://gist.github.com/danielsguima/7721b246ff38401cf8551d046c18acf7/raw/
// @updateURL
@MarMed
MarMed / README.md
Last active March 19, 2025 12:55
Routing plex traffic through an SSH tunnel

Routing plex traffic through an SSH tunnel

This guide creates a reverse SSH tunnel to route all Plex server traffic through it.

Step 2 is done on the tunnel, all other steps are done on the plex server.

1. Setup SSH keys (if you already have key based authenthication setup skip to step 2)

On plex server: