blog.smistad.me
Open in
urlscan Pro
172.104.149.76
Public Scan
URL:
https://blog.smistad.me/
Submission: On February 25 via api from US — Scanned from US
Submission: On February 25 via api from US — Scanned from US
Form analysis
0 forms found in the DOMText Content
HOME ITCHY blog > tech-debt Admin 2023-10-10 I have an itch. I've been working on a project for my company for almost 2 years now. It's fun, important, delivers value, and solves actual problems and all that. But there's a but. The traffic volume is low, yet I have an itch for big traffic volume that my current back-scratcher can't reach. So, I want to build a back-scratcher that can reach that low (var low = "high"). My idea revolves around some sort of satire page, presented kinda like a newspaper. I'm terrible at writing and content generation, so I think I'll make heavy use of ChatGPT. My idea revolves around creating caricatures of public figures and having them be the "authors". The input to GPT will be a character definition describing the author and his or her exaggerated quirks and idiosyncrasies, along with a prompt for the article I want it to write. I hope this will add a double layer of humor that will make people want to read the stuff. It also makes the resulting content less serious and more obviously fake. I don’t plan to automate the content generation part completely, I want to avoid just pushing an endless stream of AI content to the web. In DALLe mind this is a whimsical office back-scratching machine for the office. Looks similar to the machine in our office we feed under-performing PFYs too. REINVENTING THE WHEEL WordPress is the best option, but I don’t like PHP and don’t want to learn it, and it’s not fun to use something off the shelf anyway. So let's start on my nth journey of reinventing the wheel, and let's see how long I can go before being distracted by the new and shiny thing. In my mind my idea is funny, but in DALLe's mind my idea is evil. Maybe I shouldn't have sent so much of my code to ChatGPT, I'm giving it nightmares. I have some interesting technical problems I want to introduce to the project: 1. A/B testing of headlines and images 2. Some sort of algorithm for the front page - which article is shown where and in what order 3. Build a service for media content - covering resizing, etc 4. Front-end article editor 5. Performance - I don’t want to spend more than $10 a month on hosting I want to use tech stacks I haven’t used before, but it’s a bit risky. If I don’t end up enjoying the stack, then the project might quickly die. So, I only plan on using new stuff in some smaller areas. I’m purposely splitting up the project into more parts so I will be able to have smaller domains covered by different stacks. The core app will be a .NET Blazor project. I intend to do only server-side rendering, as a newspaper-like web app doesn’t really need anything client-side, and I really want to avoid using JavaScript or TypeScript. I’m very familiar with .NET, as it is what I mostly use at work, but Blazor will be newish. I made some planning poker agile vomit tool using an early Blazor version, and hated working on it. It’s truly terrible for the frontend, but is actually very nice for just templating. With the new server-side rendering stuff, it seems to be a pretty good fit. So, the core app covering the front page and article view will be .NET Blazor. For the CDN, I want to try .NET AOT API. It’s a very similar stack to the core app but will only have an API and no client. I partly ended up with .NET again because I want to test the .NET AOT stuff and Aspire, it has a pretty dashboard with graphs. The downside with AOT is that Entity Framework (a .NET ORM) does not work with AOT, so I have to rawdog the SQL directly, which probably is the best thing for a CDN anyway. The initial goal is images and static files, but I might want to do some video at some point. I don’t want to use cloud stuff; it’s too expensive and not fun. So, I will be storing the files myself, which is also not fun. I don’t want to pollute the database with many blobs, so I think I will stick with storing paths to files in the DB, and then having some structure on disk. I have had success earlier with having lots of files on disk using a bucket system. Most filesystems seem to struggle with many entries in a single directory, so splitting things up will be good. Since I’m doing resizing and conversions of images, a single upload will create many files on disk. I read some stuff about how they created a filesystem database thing for iCloud, so a possible future fun project is creating a filesystem. I think the CDN might be a Rust candidate in the future, as I want high performance from it. .NET has ImageSharp for working with images. I want to avoid using ImageMagick, because if user-uploaded images ever become a feature, I definitely don’t want ImageMagick touching that stuff. But ImageSharp is painfully slow. I did some stuff where ImageMagick was compiled in the browser, and that was faster. It’s not a big problem now, the volume of uploads will be small, probably forever. For the publishing app, the article editor I’m going full memes. HTMX frontend and rust backend. Both are new stuff for me. I tried learning rust once using the cookbook, but that’s too boring and I couldn’t come up with something fun to make, so it petered out. But I have something concrete to make now, that will be more than just a demo. I will need to make a small API, talk with a database, and render some templates. Simple CRUD, but enough moving parts that it feels like something real. Also plenty of of expansion things to look at. Can I add it to Aspire? Can I collect metrics and push that to Aspire? Logging solutions? Also more features like displaying live user statistics, and creating layout for the front pag. Graphs <3 Anyhow, this post should be published to my new blog using the project in blog mode. So if you are reading this I actually got some code to compile. --------------------------------------------------------------------------------