Commit Graph

674 Commits

Author SHA1 Message Date
Brian Cunnie
673fb34ce9 Deprecate old Concourse CI pipelines
- I don't need the "badges" pipeline anymore. It was once something that
  made me terribly proud, and I'm sad to let it go.
- Similarly with the PWS pipeline. PWS is long-gone, and I don't know
  why I kept it around so long because I didn't have any emotional
  attachment to it
- I certainly don't need the task file for checking the nameservers;
  that's a Concourse CI-thing.
2025-01-19 06:25:04 -08:00
Brian Cunnie
1f4b183d0c GitHub Actions: Descriptive name when checking nameservers
Previously this action was called "Check DNS", but that was confusing
because this repo is all about DNS, so to be more clear we are calling
it "Check Nameservers" because that's what we're doing — checking that
the sslip.io nameservers are running properly.
2025-01-19 05:46:41 -08:00
Brian Cunnie
06fa9efdd0 🐞 GitHub Actions: server test uses domain
This variable, `DOMAIN`, is carried over from Concourse CI, but I
probably should've hard-coded it.

Fixes, when running GitHub actions:

```
Usage: whois [OPTION]... OBJECT...
```
2025-01-19 05:36:18 -08:00
Brian Cunnie
489ed15ee6 🐞 GitHub Actions: server test uses correct directory
Concourse uses the directory above the repo; GitHub actions uses the
repo. This commit adjusts the director to accommodate GitHub Actions.

Fixes:

```
LoadError:
  cannot load such file -- /__w/sslip.io/sslip.io/sslip.io/spec
```
2025-01-19 05:22:08 -08:00
Brian Cunnie
2a5d9dc649 GitHub Actions: cron job every 6 hours tests servers
Drive-by: I reformatted the two GitHub Actions files
2025-01-19 05:17:24 -08:00
Brian Cunnie
c6c7c9b73c Releases are done manually, not with GitHub Actions
I'm not ready to convert the release process, which is fairly
complicated, to GitHub actions. And the simple job is inadequate and
does the wrong thing (e.g. doesn't embed version numbers).
2025-01-19 05:14:02 -08:00
Brian Cunnie
4d6adde5a9 CI runs on GitHub Actions
- on a self-hosted runner
- pull requests don't trigger actions (security)
- forks don't trigger actions (security)
- run in a container (fedora-golang-bosh) (security)
2025-01-18 19:16:17 -08:00
Brian Cunnie
6027636bbd First pass at GitHub actiosn to run CI/CD
Concourse has stood me in good stead these past years, but development
has stalled with the Pivotal → VMware → Broadcom acquisitions, and now,
with the expiration of one of my Google Cloud Platform committed use
discounts, is a good time to transition to GitHub actions.
2025-01-18 06:11:43 -08:00
Brian Cunnie
64cf7b6bc1 3.2.6: -ns-azure, ns-aws → "blocked" 3.2.6 2025-01-04 11:51:18 -08:00
Brian Cunnie
7d6b724cbe Remove traces of nameservers ns-aws, ns-azure
- ns-aws & ns-azure have been replaced by ns-hetzner & ns-ovh
- ns-azure has been completely destroyed (`terraform apply -destroy`);
  the elastic IP has been released, so there's no hope of bringing it
  back.
- ns-aws has been renamed to "blocked.sslip.io". It no longer answers
  DNS queries, but lives on as the website we point "blocked" queries to
  that warns about phishing.
- Some of the Markdown files' changes were mere reformatting changes
2025-01-04 11:28:40 -08:00
Brian Cunnie
70c0b3ca74 Update SOA to 01/01
New year deserves new SOA
2025-01-04 08:10:04 -08:00
Brian Cunnie
a8cf468b72 Bump dependencies
```bash
go get -u -t; go mod tidy
go install golang.org/x/tools/cmd/goimports@latest
go install github.com/onsi/ginkgo/v2/ginkgo@latest
```
2025-01-04 08:07:06 -08:00
Brian Cunnie
0dfbe21d1d I'm not looking for pull requests 2024-12-28 05:33:58 -08:00
Brian Cunnie
a17e9cc8c0 🐞 Make metrics more readable (no Unicode)
When using dig to determine the metrics of my servers, e.g. "dig txt
metrics.status.sslip.io @ns-ovh.sslip.io +short", one record looks
particularly heinous:

```
"Answer \226\137\165 1: 67974722 (651.9/s)"
```

It's supposed to look like this:

```
"Answer ≥ 1: 67974722 (651.9/s)"
```

`dig` doesn't handle Unicode well. So I'm replacing "Answer ≥ 1" with
"Answer > 0". No Unicode.

It was a worthy effort, but ultimately failed.
2024-12-04 18:16:17 -08:00
Brian Cunnie
508f058a7a 3.2.5: Minor bugfixes, tweaks 3.2.5 2024-12-03 11:07:07 -08:00
Brian Cunnie
b497beddd2 Deprecate custom listLocalIPCIDRs()
We don't need a custom `listLocalIPCIDRs()`; Golang now has a builtin:
`net.InterfaceAddrs()`. [0]

This is one of those wonderful commits that removes more lines than it
adds.

[0] https://pkg.go.dev/net#InterfaceAddrs
2024-12-03 11:21:06 -05:00
Brian Cunnie
0fc3c81641 Replace ambiguous metric, "Answered Queries"
I've always been uncomfortable with the metric "Answered Queries" — it
implies that we don't answer all the queries. But we do answer all the
queries!

What the metric meant is "the number of DNS responses that we send that
have one or more records in the ANSWER section".

The new metric is "Answer ≥ 1". Not great, but better than before.
2024-11-19 09:25:10 -08:00
Brian Cunnie
3ed466bc74 Placate the linter
- check for errors when I was previously skipping them
- use module `time` better

Drive-by: Shorter way to copy the new `index.html` to the 5 servers.
2024-11-17 07:22:37 -08:00
Brian Cunnie
8c89816eeb 🐞 ns.sslip.io → +ns-hetzner, -ns-azure
When I had introduced ns-hetzner, I forgot to update the records for
ns.sslip.io, which continued to point to the old, deprecated ns-azure.

This commit updates the ns.sslip.io records.
2024-11-17 06:54:33 -08:00
Brian Cunnie
cb2424ac2a web page: +ns-hetzner, -ns-azure
- remove the alert about not using the sslip.io nameservers as
  general-purpose nameservers — I feel if they're looking at the page,
  they already know enough not to use the nameservers as recursive
  nameservers.
- deprecate ns-azure.
- extend the shutdown to 12/25 for ns-aws & ns-azure
- add a shoutout to Let's Encrypt
2024-11-16 20:02:14 -08:00
Brian Cunnie
1eab46ca7c index.html; use VS Code to format, not tidy
`tidy`, a UNIX-based HTML-formatter, has had its day in the sun, but
with the advent of VS Code, which I'll be using often to modify the
HTML, it makes more sense to format within the editor rather than in a
separate terminal window.
2024-11-16 19:05:41 -08:00
Brian Cunnie
1da3b67af2 3.2.4: Introduce new nameserver, ns-hetzner.sslip.io 3.2.4 2024-11-16 17:26:04 -08:00
Brian Cunnie
30d51c3014 Update SOA to 11/15
Jon Penn's birthday; probably the most life-changing birthday party I've
ever been to.
2024-11-16 16:09:43 -08:00
Brian Cunnie
ce852009c5 "ns-azure is dead, long live ns-hetzner"
The nameserver on Azure is probably my least-favorite: much slower, much
higher latency. Even though it would've made more geographic sense to
dismantle my GCP nameserver in favor of the Hetzner, I'm using this
opportunity to get rid of the Azure.

And, of course, introduce the Hetzner nameserver with its 20TB of
bandwidth allowance, which I've come to need.
2024-11-16 16:02:25 -08:00
Brian Cunnie
f6c3fca560 Heck, let's dedicate the entire service to Roopinder
It feels lonely not having him around.
2024-11-11 08:40:28 -08:00
Brian Cunnie
1ed661419b Let's dedicate this to Roopinder 2024-11-11 08:37:53 -08:00
Brian Cunnie
680fa3d8f3 Schedule de-commissioning of ns-aws
It costs too much.
2024-11-11 07:48:50 -08:00
Brian Cunnie
7a26f40ee6 Warn white labellers to update their NS servers
ns-aws.sslip.io is deprecated.

Drive-by: used absolute paths in the description of how I can use the
logs.
2024-11-07 17:41:14 -08:00
Brian Cunnie
ad91ae880e DEVELOPER instructions: corrected wrong comments 2024-11-07 07:17:36 -08:00
Brian Cunnie
c6c5435e4a 3.2.3: ns-aws is no longer an NS for sslip.io 3.2.3 2024-11-04 18:14:17 -08:00
Brian Cunnie
ef731f067d Update SOA to 11/5
The late, great Tom Casey's birthday
2024-11-04 18:05:37 -08:00
Brian Cunnie
ab78120615 Bump dependencies go get -u -t; go mod tidy 2024-11-04 18:02:33 -08:00
Brian Cunnie
34318bbb43 Retire DNS server, ns-aws.sslip.io
The torrent of traffic I'm receiving has caused my AWS bill to spike
from $9 to $148, all of the increase due to bandwidth charges.

I'm still maintaining ns-aws; the VM still continue to run, and continue
to serve web traffic, and maintain its hostname and IP addresses;
however, it will no longer be in the list of NS records for sslip.io.

There are much less expensive hosting providers. OVH is my current
favorite.
2024-11-04 17:56:03 -08:00
Brian Cunnie
1f7a54db73 Revert "Introduce new flag, -max_queries_per_sec"
Rather than bloating the code with yet another flag, one that only I
would use, and in only one specific case (ns-aws.sslip.io), it would be
better to simply take ns-aws.sslip.io out of the NS list.
2024-11-04 07:16:52 -08:00
Brian Cunnie
9c8712578d Introduce new flag, -max_queries_per_sec
I'm being gouged by bandwidth costs by AWS. Last month's bill was $148,
and all but $9 was about bandwidth.

My bandwidth has been inexplicably climbing since February:

Billing
Month   Total GB % increase

2024/2		  37.119
2024/3		  52.953	42.66%
2024/4		  58.745	10.94%
2024/5		  69.307	17.98%
2024/6		 173.371	150.15%
2024/7		 334.064	92.69%
2024/8		 539.343	61.45%
2024/9		 568.745	5.45%
2024/10	1365.305	140.06%

The new flag will allow me to throttle the AWS bandwidth to ~287 queries
/ second, which, according to my calculations, will max out the free
100 GB bandwidth without dipping into the for-pay bandwidth.
2024-11-03 17:35:46 -08:00
Brian Cunnie
078a69f75e 3.2.2: Join the Public Suffix List 3.2.2 2024-10-08 18:53:08 -07:00
Brian Cunnie
dea655a990 TXT record attests ownership for the Public Suffix List
We want to place sslip.io on the Public Suffix List so we don't need to
pester Let's Encrypt for rate limit increases.

According to https://publicsuffix.org/submit/:

> owners of privately-registered domains who themselves issue subdomains
to mutually-untrusting parties may wish to be added to the PRIVATE
section of the list.

References:

- https://publicsuffix.org/
- https://github.com/publicsuffix/list/pull/2206

[Fixes #57]
2024-10-08 18:08:59 -07:00
Brian Cunnie
39d876079c Update SOA to 10/8
Lucy's birthday.
2024-10-08 09:09:24 -07:00
Brian Cunnie
705c50b70e Bump dependencies go get -u -t; go mod tidy 2024-10-08 09:06:54 -07:00
Brian Cunnie
8eb5d82e83 Who is querying us the most? 2024-09-23 07:20:21 -07:00
Brian Cunnie
d0c3927415 3.2.1: Return NS records in random order 3.2.1 2024-09-17 06:34:32 -07:00
Brian Cunnie
63a2be439e Return NS records randomly
Previously when the NS records were returned, ns-aws was always returned
first. Coincidentally, 64% of the queries were directed to ns-aws. And
once I exceeded AWS's 10 TB bandwidth limit, AWS began gouging me for
bandwidth charges, and $12.66/month rapidly climbed to $62.30

I'm hoping that by randomly rotating the order of nameservers, the
traffic will balance across the nameservers.

Current snapshot (already ns-ovh is helping):

ns-aws.sslip.io
"Queries: 237744377 (1800.6/s)"
"Answered Queries: 63040894 (477.5/s)"

ns-azure.sslip.io
"Queries: 42610823 (323.4/s)"
"Answered Queries: 14660603 (111.3/s)"

ns-gce.sslip.io
"Queries: 59734371 (454.1/s)"
"Answered Queries: 17636444 (134.1/s)"

ns-ovh.sslip.io
"Queries: 135897332 (1034.4/s)"
"Answered Queries: 36010164 (274.1/s)"
2024-09-17 06:27:53 -07:00
Brian Cunnie
c4310ebb86 3.2.0: Introduce new nameserver, ns-ovh.sslip.io 3.2.0 2024-09-15 17:45:01 -07:00
Brian Cunnie
6855598f0f Introduce new name server, ns-ovh.sslip.io
- located in Warsaw, Poland
- IPv4: 51.75.53.19
- IPv6: 2001:41d0:602:2313::1

The crux of this is to take the load off ns-aws, which jumped from
$12.66 → $20.63 → $38.51 → $62.30 in the last four months due to
bandwidth charges exceeding 10 TB.

The real fix is to randomize the order in which the nameservers are
returned.
2024-09-15 17:21:16 -07:00
Brian Cunnie
afe851a867 Dismantle DNS-backed key-value store, k-v.io
I'm no longer engaged on setting up k-v.io; I thought it'd be cool to
have a DNS-backed etcd implementation, but now I don't care anymore.

There were technical challenges, too: Specifically, updating values did
not play well with DNS caching — you'd get the old value after updating.

If the service became popular, I'd quickly run out of disk space on my
tiny cloud VMs.

The service would most likely be used by people doing data exfiltration
via DNS. I already have enough problems with sslip.io scammers — the
last thing I want is to sign up for dealing with k-v.io scammers.

This commit removes the etcd configuration, certificates, and pipelines.
2024-09-15 07:30:57 -07:00
Brian Cunnie
450fc67a57 Prune unused default.json
I had big plans for feeding in the configuration of the DNS server with
a JSON file, but since then I've come to consider command-line flags
good enough, so there's no reason to leave this useless file lingering —
it'll only server to confuse.
2024-09-15 06:54:43 -07:00
Brian Cunnie
4111f7c1ba Update SOA to 9/15
In preparation of adding a new nameserver, ns-ovh.sslip.io
2024-09-15 06:48:45 -07:00
Brian Cunnie
76d27df591 Bump dependencies go get -u -t; go mod tidy 2024-09-15 06:44:49 -07:00
Brian Cunnie
ba85d1aacf 🐞 Remove incorrect -delegates warning
fixes, when server is started with `-delegates` unset:

```
-delegates: arguments should be in the format "delegatedDomain=nameserver", not ""
```
2024-07-04 05:47:45 -07:00
Brian Cunnie
74a5c2edfd Bump Ruby 3.1 → 3.3 (for rspec) 2024-06-17 06:22:42 -07:00