- Using a ready-to-use Ubuntu image
This was a huge hassle to figure out, so I wrote up a little guide in hopes that others would find it helpful:
How to convince macOS to do IPv6 DNS lookups when your only IPv6 address is via a VPN or tunnel of some sort
macOS's domain name resolver will only return IPv6 addresses (from AAAA records) when it thinks that you have a valid routable IPv6 address. For physical interfaces like Ethernet or Wi-Fi it's enough to set or be assigned an IPv6 address, but for tunnels (such as those using utun interfaces) there are some extra annoying steps that need to be taken to convince the system that yes, you indeed have an IPv6 address, and yes, you'd like to get IPv6 addresses back for DNS lookups.
I use wg-quick to establish a WireGuard tunnel between my laptop and a Linode virtual server. WireGuard uses a utun user-space tunnel device to make the connection. Here's how that device gets configured:
Hey everyone - this is not just a one off thing, there are likely to be many other modules in your dependency trees that are now a burden to their authors. I didn't create this code for altruistic motivations, I created it for fun. I was learning, and learning is fun. I gave it away because it was easy to do so, and because sharing helps learning too. I think most of the small modules on npm were created for reasons like this. However, that was a long time ago. I've since moved on from this module and moved on from that thing too and in the process of moving on from that as well. I've written way better modules than this, the internet just hasn't fully caught up.
@broros
otherwise why would he hand over a popular package to a stranger?
If it's not fun anymore, you get literally nothing from maintaining a popular package.
One time, I was working as a dishwasher in a restu
| even_letters = "bcdfghlmnprstwx" | |
| odd_letters = "aeiou" | |
| def format_uid_digit (n, level): | |
| if n != 0: | |
| letters = odd_letters if (level & 1) else even_letters | |
| base = len(letters) | |
| s = format_uid_digit(n / base, level + 1) | |
| return s + letters[(n % base)] | |
| return "" |
This is a quick explanation of how to configure both ZeroTier and two Ubiquiti UniFi USGs to allow routing between two IPv4 networks. Both networks are in private (RFC1918) address space and each one has its own DHCP service. There is no need for NAT between them, only IP routing.
The two networks are 192.168.1.0/24 (call this the "left" network) and 192.168.10.0/24 (the "right" network) but they can be anything. Also, you can have multiple CIDR blocks on one side or the other of the ZeroTier route; if you do, you just have to create more routing table entries.
| const compose = (f, g) => x => f(g(x)) | |
| const Id = x => | |
| ({ | |
| fold: f => f(x), | |
| map: f => Id(f(x)) | |
| }) | |
| Id.of = Id | |
| const Tuple = (_1, _2) => |
| #include <stdio.h> | |
| #include <stdbool.h> | |
| // Maybe | |
| typedef struct MaybeInt { | |
| int just; | |
| bool nothing; | |
| } MaybeInt; |
| # Backup files | |
| #https://explainshell.com/explain?cmd=rsync+-azuv+--delete+--progress+--exclude+%27node_modules%27 | |
| rsync -auvhp --delete --exclude=node_modules [source] [destination] | |
| # Remove all node_modules folders | |
| # https://explainshell.com/explain?cmd=find+.+-name+%22node_modules%22+-type+d+-prune+-exec+rm+-rf+%27%7B%7D%27+%2B | |
| find . -name "node_modules" -type d -prune -exec rm -rf '{}' + |
| // https://medium.com/@WebReflection/dom-handleevent-a-cross-platform-standard-since-year-2000-5bf17287fd38 | |
| export default class DOMEventHandler { | |
| constructor(ctx, node) { | |
| if (!ctx) throw new Error("DOMEventHandler: A context is required."); | |
| this.ctx = ctx; | |
| if (node) this.addEventListeners(node); | |
| } | |
| get events() { | |
| return ( |
| { config, pkgs, lib, ... }: | |
| { | |
| # NixOS wants to enable GRUB by default | |
| boot.loader.grub.enable = false; | |
| # Enables the generation of /boot/extlinux/extlinux.conf | |
| boot.loader.generic-extlinux-compatible.enable = true; | |
| # !!! If your board is a Raspberry Pi 1, select this: | |
| # boot.kernelPackages = pkgs.linuxPackages_rpi; | |
| # !!! Otherwise (even if you have a Raspberry Pi 2 or 3), pick this: |