toasterdragon
:: what ::

recent posts
How This Site Works

How this site works

I’d like to write out how I set this website up, since I think it’s kind of interesting. This website is hosted on a VPS that a friend generously provisioned for me. It’s nothing powerful or fancy, but it’s more than enough for this setup. This site uses Hugo, nginx, certbot, Gitea, and webhook.

Hugo

Hugo is a static site generator. It’s not a heavy program like WordPress that generates the HTML when the page is requested. It just chews up markdown files and spits out HTML. You set up themes using HTML and CSS, which I found to be very straightforward despite my minimal web development experience. There’s no javascript, no database queries, just static HTML. Everything is generated from a folder full of markdown, HTML, and CSS files.

Packaging things up

I need to learn more about RPM packages, and I figured a good way to do that would be packaging my little Patissiere application. Before I do that though, I need a systemd unit file.

So a common complaint I’ve heard from systemd detractors is that the old school init scripts were really easy to read / write and that this newfangled systemd stuff is a lot more difficult.

patissiere.service

Patissiere

I want to work on a rust web app. A pastebin is a simple project that I should be able to complete before I get bored of it. I was told of axum, which seems to be a pretty easy way to get a webapp going.

According to the docs, our hello world with axum goes something like:

use axum::{
    routing::get,
    Router,
};

#[tokio::main]
async fn main() {
    // build our application with a single route
    let app = Router::new().route("/", get(|| async { "Hello, World!" }));

    // run our app with hyper, listening globally on port 3000
    let listener = tokio::net::TcpListener::bind("0.0.0.0:3000").await.unwrap();
    axum::serve(listener, app).await.unwrap();
}

That’s kind of a lot! I’m pretty new to rust, but this doesn’t seem too bad. Let’s take a look at what that does.

LibreSprite Adventures

My friend asked me for a little 88x31 badge to add to their site, so they could link to mine. I thought it would be a cute little project, so I installed LibreSprite, a free and open source sprite program. It was available in my distro’s repositories, so installing it was quick and easy.

After launching it for the first time, I was able to quickly create a new file. The UI is clean and intuitive. LibreSprite is a sprite creation tool, seemingly aimed at game developers, but it seems like it will comfortably allow work with a 88x31 canvas, perfect for my needs.

Links

zombo.toasterdragon.com

zombo.com was taken over by a sloperator, so please enjoy

rhizomatic queer ascendance toasterdragon.com