RSSAmplifier

Blog

John's Blog

A personal blog about technology, programming, and software development

blog.jlcarveth.devRSS feed ↗15 posts

Latest posts

Building Debian Packages on Arch Linux with systemd-nspawn

My desktop PC predates my love for Debian, so it's still running Arch Linux. I ran into an issue the other week while working from home while trying to build a Debian package: ❯ make package Cleaning build artifacts... rm -rf debian/cassandra rm -rf debian/.debhelper rm -rf debian/files rm -f debian/cassandra.debhelper.log rm -f debian/cassandra.substvars rm -f debian/*.log rm -f ../*.deb rm…

Packaging Deno Programs for Debian

Lately, I find myself writing a lot of programs using the Deno runtime, and I wanted an easier way to install these programs on various development and production environments. My development machine, local development server, as well as my production server all run Debian, so it made sense to learn how to package my programs the Debian way . This article will detail the steps I took to package a…

Hardening systemd Services

My love for systemd is no secret, I've blogged about it more than once. I especially love systemd's ability to harden services. What does this mean exactly? Systemd offers a wealth of directives that can restrict a service's access to files, syscalls, or even the network. This gives me peace of mind, knowing that even if the software running in the service has a vulnerability, the…

Four Command-Line Tools Boosting My Productivity

They always say a man is only as good as his tools, and that remains true in the world of computing. As I gain more experience in the terminal, I've discovered some powerful utilities which have vastly improved my productivity and developer experience. Better Shell History Lookup The first program I would like to direct your attention to is fzf . fzf is a fuzzy finder , meaning it…

Using the Clipboard from the Command Line

This will be a brief post, but I wanted to share some helpful aliases I use every single day: Prerequisites These aliases make use of xclip , which is not usually included by default in most Linux distributions. Make sure it's installed: sudo apt-get install xclip # Debian/Ubuntu sudo dnf install xclip # Fedora sudo pacman -S xclip # Arch Linux The Aliases alias pbcopy='xclip -r…

Setting Up Systemd Email Notifications with SendGrid

After a recent service outage that went unnoticed longer than I'd like to admit, I decided to set up automatic email notifications for any systemd service failures. Here's how I accomplished this using systemd and SendGrid. The Setup The solution consists of three components: A top-level systemd drop-in that triggers on any service failure A template unit that handles the notification…

Exploring the MangoPi - A Journey into RISC-V Assembly.

Introduction I have held an interest in Single-Board Computers (SBCs) for a while now, and my journey eventually led me to the MangoPi. In this blog post, I'll take you through my exploration of this intriguing single-board computer, powered by the AllWinner D1 SoC with its revolutionary RISC-V-based core. Join me as I delve into the process of installing Linux on the MangoPi, connecting via…

Systemd Units vs Docker Containers - Why I Choose the Former for Running Services

Docker is a great tool for building and running containerized applications, but it is not the best solution for running services on Linux. In this post, I will explain why I prefer using systemd units over Docker containers for running services on Linux, based on three criteria: simplicity, integration, and reliability. Simplicity Docker simplifies the process of creating and deploying…

Introducing Nutty Version 1.0: A Self-Hosted HTTP Paste Server

I am excited to announce the release of version 1.0 of Nutty 1 , an HTTP paste server that allows for easy storage and sharing of plaintext files via a simple HTTP API. With Nutty, you can self-host your own paste server and have complete control over your data. The software is easy to use and comes with a simple example bash client that encrypts all text before sending it to the server, ensuring…

Bringing the Power of an IDE to the Terminal

Recently, I decided to take the plunge and switch from my usual editor-of-choice, VSCode, to the terminal-based Neovim. I had already been using the terminal for more and more things in my day-to-day workflow, and I had a sense of the power and efficiency it offered. It was only when I read a comment on a Hackernews thread about "living in the terminal" that I decided to take the plunge. That…

Implementing Role-based Access Control (RBAC) with Express.js and SQLite

Role-based access control (RBAC) is a valuable technique for restricting access to computer resources based on a user's role within that system. Imagine an organization with multiple departments. An employee who works in shipping and recieving will need access to a "Shipping" view in an application, but has no need to access the "Expense Reports" view. RBAC facilitates rules such as this…

Generating a Logo Using Dall-E

I was recently granted access to Dall-E , a new artificial intelligence that can generate images from a single text prompt. I had already read an article about generating a logo using the technology and I knew it was something I wanted to pursue. So I went about generating some images. The first prompt I tried was incredibly succinct: cute mascot logo . The results are interesting. The first image…

Monitoring a Directory with Systemd

I've been using Linux as my daily driver OS for a couple of years now, but it's only recently that I started using Linux everyday as a part of my job. A lot of those days, I find myself using systemd . It's wonderful. I can manage software deployments, schedule tasks, listen to network sockets, and as the title of this article suggests I can use systemd to monitor a certain path for…

Scheduling Tasks with Systemd Timers

I have been using systemd to manage services on my many Linux boxes for a while now. Compared to writing initd scripts, systemd service files are dead simple. Recently, I needed to setup a backup solution for a new linux box being setup at work. This server was running Ubuntu Server 22.04, which comes with systemd 249 (249.11-0ubuntu3.4) out of the box. Our ideal backup solution would backup only…

Welcome to blog.jlcarveth.dev

This is the first post on the blog setup using Deno . What is Deno? Deno is a modern Javascript / Typescript runtime built upon V8. Deno was built by Ryan Dahl, the creator of Node.js. Unlike Node.js, Deno supports existing web platform APIs such as fetch and the Streams API rather than creating new APIs to learn. Deno as a Blogging Platform Deno's simplicity is an extremely appealing…