Hey, it looks like a resource failed to load. If you have an ad-blocker, please turn it off.

Dark Mode Light Mode

The Great Migration

Updated 5:55 on 1/9/2025

NearlyFreeSpeech.NET and I

My previous hosting provider was NearlyFreeSpeech.NET. They are a no-nonsense, very simple (in the services they provide) hosting service for experienced developers/website maintainers.

I am not an experienced developer for websites. My main experience comes primarily from ASP.NET, which NearlyFreeSpeech.NET doesn't support by default. When I first started with this website, I hosted it via node.ts, which certainly worked, but had major issues.

  • Post storage: at first I had a custom format in text files which were read from at run-time, but wow, this sucked, so I moved to a database. NearlyFreeSpeech.NET only supports MariaDB, but Typescript had very poor support for this database server, which meant a lot of my code was hacky!
    • See my database.ts file on my website's repository here.
    • Warning: it's not great. I also hated writing that code.
  • Post generation. On the same link above, I struggled a lot with how best to have a generic page for the client instead of copying HTML. .NET solves this quite well with Razor pages, but for TypeScript? I had no idea how to approach the problem, which led to things like this.
  • Lack of standard authorization for private pages on my site. I've moved to a new method which is, honest to god, a lot more secure, but my god, what the hell was I supposed to do? A query parameter to give a user an authentication token was the best I could do.
  • In general, I just don't like TypeScript for back-ends. In my opinion, TypeScript does one thing well: it makes JavaScript more document-able by including clearly defined types and throwing exceptions if they aren't what's expected.
    • I maintain that JavaScript's automatic type casting to make an operation work even if it shouldn't is one of its biggest flaws. Make my program fail loudly, damn it! Make me handle the edge cases instead of letting them propagate and causing issues!

This isn't to say that TypeScript doesn't have solutions for this. The NPM marketplace is truly incredible, and the amount of free packages that can make an application work better? Incredible.

The main issue is that there's no standard, at least as far as I could tell. There are, let's say, four solutions for authentication and authorization, but nothing exists in TypeScript that I can use. They're all from independent package creators, which is great, but it does make every application a teetering tower of troubles when a package has an issue.

This is somewhat solved by having Microsoft back .NET development, but that just moves the issue. What happens if Microsoft stops supporting certain parts of .NET?

I digress. I decided to move my back-end to ASP.NET after running into several of these issues, the final one being the poor MariaDB support. However, I wasn't able to initially because NearlyFreeSpeech.NET doesn't support .NET out of the box!

This sucks! But I was able to request an installation of .NET 8 on their "Black" hosting realm (experimental). I switched my site to it, ran the new site back-end rewritten for .NET, and it worked. Joy to all.

This worked for... about four months?

The Incident

A week or so ago, I was creating update scripts for my database schema. It had languished behind in my efforts to make my website Decent To Work On™, so I decided to create some .sql scripts containing my existing schema, then update scripts. It worked pretty well, and I was able to make a lot of changes I wanted to make to the database.

I uploaded the scripts to NearlyFreeSpeech.NET's SFTP portal, and got it all working. The database had been updated through the scripts I wrote, the data was intact (I tested it on my local, but god it is nerve-wracking!) and everything looked good.

Then I tried to launch my new compiled ASP.NET webserver. Lo and behold, the world fell apart, revealing the culprit. My... database access layer DLL?

Specifically, this is the error I got when trying to run my website:

Unhandled exception. System.IO.FileNotFoundException: Could not load file or assembly 'LylinkBackend_DatabaseAccessLayer, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'. The system cannot find the file specified.

File name: 'LylinkBackend_DatabaseAccessLayer, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'

I was quickly confused. It worked fine on my machine lol. Some debugging (read: hours) later, I found the culprit. For some reason, when I attempted to run any dotnet command (aside from dotnet -h), it would throw the following exception:

System.IO.IOException: Not enough storage is available to process this command. : 'NuGet-Migrations'

Yeah, what the fuck? More debugging (read: painful hours) later, I couldn't narrow it down to anything I had done. I had to assume the culprit was the hosting service instead of my own code, and so I made a forum post.

I was told that because I was on an experimental realm, I was outside of any help. So. That was great.

The Great Migration

Obviously, I couldn't stay with NearlyFreeSpeech.NET. I love the site, their hosting is great, and I wholeheartedly recommend them for anything like Wordpress sites or static file serving. But my specific use case wasn't satisfied with them, so I had to leave.

I purchased some VPS space from a provider and over the course of some more hours (read: actually just hours this time, not painful) got the DNS, reverse proxy, and webserver set up and receiving data. Woo!

Still sucks though. I've still got my domain registered with them, but for actual hosting? I have to go elsewhere.

Farewell, NearlyFreeSpeech.NET. You're fantastic, but I flew too close to the sun and got burnt. Had to seek urgent care.