Skip to content

Instantly share code, notes, and snippets.

View n-studio's full-sized avatar

n-studio

View GitHub Profile
@n-studio
n-studio / DEPLOY_WITH_KAMAL_ON_DEDICATED_SERVER.md
Last active May 4, 2025 11:09
Deploy a web app on a dedicated server with Kamal

Notes

This guide uses Kamal 2.5.3

Motivation

Kamal was designed with 1 service = 1 droplet/VPS in mind.
But I'm cheap and I want to be able to deploy multiple demo/poc apps apps on my $20/month dedicated server.
What the hell, I'll even host my private container registry on it.

@adrienpoly
adrienpoly / application.html.erb
Last active April 30, 2025 15:45
Capybara / Stimulus test helper to ensure JS is ready when test starts
<!DOCTYPE html>
<html>
<head>
...
</head>
<body data-controller="js">
<%= yield %>
</body>
</html>
@mendelgusmao
mendelgusmao / btsync
Last active March 4, 2021 15:37
init.d script for btsync (based on another script built to run dropbox)
#!/bin/sh
### BEGIN INIT INFO
# Provides: btsync
# Required-Start: $local_fs $remote_fs
# Required-Stop: $local_fs $remote_fs
# Should-Start: $network
# Should-Stop: $network
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Multi-user daemonized version of btsync.