Create a template service file at /etc/systemd/system/[email protected]. The template parameter will correspond to the name
of target host:
[Unit]
Description=Setup a secure tunnel to %I
After=network.targetCreate a template service file at /etc/systemd/system/[email protected]. The template parameter will correspond to the name
of target host:
[Unit]
Description=Setup a secure tunnel to %I
After=network.targetNo, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.
Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.
| # tag target commits as demo-start, demo-end | |
| # move to the start of your presentration with `git checkout demo-start` | |
| # use to `git next`, `git prev` to jump between "slides" | |
| git config --global alias.next '!git checkout `git rev-list HEAD..demo-end | tail -1`' | |
| git config --global alias.prev 'checkout HEAD^' |
| """ | |
| Test performance of these counting methods: | |
| - count_if_else: Set to 1 if not yet seen and increment otherwise | |
| - count_if: Set to 0 if not yet seen, then increment regardless of containment | |
| - count_exception: Attempt to increment and set to 1 if KeyError caught | |
| - count_setdefault: Set default value to 0, then increment | |
| - count_fromkeys: Create dict with necessary keys set to 0, then increment each | |
| - count_set_and_comprehension: Create dict of items and counts using a set | |
| - count_defaultdict: Increment count, automatically setting unseen values to 0 |
| " _ _ " | |
| " _ /|| . . ||\ _ " | |
| " ( } \||D ' ' ' C||/ { % " | |
| " | /\__,=_[_] ' . . ' [_]_=,__/\ |" | |
| " |_\_ |----| |----| _/_|" | |
| " | |/ | | | | \| |" | |
| " | /_ | | | | _\ |" | |
| It is all fun and games until someone gets hacked! |
After reading [this Ars Technica article][1], I decided that I wanted to start using btrfs on my home fileserver. It had been running for a few years with an mdadm raid-10 array, formatted with ext4, holding about 3.4 TB of data. I figured I would take advantage of some of the special capabilities of btrfs to perform the conversion in place. After some research, I formed my basic plan.
| function readWholeStdin() { | |
| process.stdin.resume(); | |
| process.stdin.setEncoding('utf8'); | |
| var buffer = ''; | |
| process.stdin.on('data', function(chunk) { | |
| buffer += chunk; | |
| }); | |
| var deferred = Q.defer(); | |
| process.stdin.on('end', function() { |
| # This enables a publicly available server to forward connections to your computer behind a NAT. | |
| # So if you access http://xx.xx.xx.xx:8080/ on your browser, traffic is redirected to your machine behind a NAT. | |
| # on your local host, type: | |
| ssh -R xx.xx.xx.xx:8888:localhost:80 [email protected] | |
| # now wait for your shell, and type: | |
| socat TCP-LISTEN:8080,FORK TCP:127.0.0.1:8888 | |
| # This command outputs nothing, just keep it running. While you don't ^C, your tunnel is up and running! |
| import numpy as np | |
| import rasterio | |
| """ | |
| 2014-02-13 | |
| Bryan Luman | |
| Use it however you like at your own risk | |
| Problem: | |
| I have a huge DEM converted from LiDAR LAS points. I'd like to make it slightly |