Skip to content

Instantly share code, notes, and snippets.

@mattiaslundberg
mattiaslundberg / Ansible Let's Encrypt Nginx setup
Last active May 14, 2025 21:35
Let's Encrypt Nginx setup with Ansible
Ansible playbook to setup HTTPS using Let's encrypt on nginx.
The Ansible playbook installs everything needed to serve static files from a nginx server over HTTPS.
The server pass A rating on [SSL Labs](https://www.ssllabs.com/).
To use:
1. Install [Ansible](https://www.ansible.com/)
2. Setup an Ubuntu 16.04 server accessible over ssh
3. Create `/etc/ansible/hosts` according to template below and change example.com to your domain
4. Copy the rest of the files to an empty directory (`playbook.yml` in the root of that folder and the rest in the `templates` subfolder)
@2001db8
2001db8 / LUKS_SSH.md
Last active March 15, 2020 22:59
Decrypt LUKS volume at boot via SSH on CentOS 7

Download https://github.com/mk-fg/dracut-crypt-sshd and unzip

yum groupinstall "Development Tools"
yum install dropbear
cp -R 60dropbear-sshd /usr/lib/dracut/modules.d/
echo 'add_dracutmodules+="dropbear-sshd"' >> /etc/dracut.conf.d/dropbear.conf
echo  'dropbear_port=22' >> /etc/dracut.conf.d/dropbear.conf

Then edit GRUB_CMDLINE_LINUX line in /etc/default/grub and add

@PurpleBooth
PurpleBooth / README-Template.md
Last active July 6, 2025 08:17
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@L422Y
L422Y / osx_automount_nfs.md
Last active May 11, 2025 19:36
Automounting NFS share in OS X into /Volumes

I have spent quite a bit of time figuring out automounts of NFS shares in OS X...

Somewhere along the line, Apple decided allowing mounts directly into /Volumes should not be possible:

/etc/auto_master (see last line):

#
# Automounter master map
#

+auto_master # Use directory service