Skip to content

Instantly share code, notes, and snippets.

View xor-gate's full-sized avatar
👽

Jerry Jacobs xor-gate

👽
View GitHub Profile
@xor-gate
xor-gate / 0-README.txt
Created January 20, 2024 12:49 — forked from yan-foto/0-README.txt
DeDRM Adobe Digital Edition Books
Convenient DeDRM Scripts
-------------------------
**NOTE**: read https://blog.quaintous.com/2021/02/16/remove-drm-from-ebooks/ to find out what this gist is good for.
* ./init.sh: extracts Adobe Digital Editions private key and required files to DeDRM.
* ./dedrm: removes DRM from given ebook (pdf/epub)
If you are using this for the first time, make sure that you have authenticated your Adobe Digital Editions (ADE) and run './init.sh'. Import any DRM-protected file into ADE and run 'dedrm.sh':
#include <WiFi.h>
#include <SPIFFS.h>
#include <ESPAsyncWebServer.h>
#include <WebSocketsServer.h>
// Constants
const char *ssid = "ESP32-AP";
const char *password = "LetMeInPlz";
const char *msg_toggle_led = "toggleLED";
const char *msg_get_led = "getLEDState";
@xor-gate
xor-gate / README.markdown
Created April 1, 2023 08:21 — forked from openfirmware/README.markdown
Restoring ZFS Snapshots of PostgreSQL Database

ZFS Snapshots and PostgreSQL

I recently set up a host running Ubuntu 14.04 LTS, ubuntu-zfs, and PostgreSQL 9.3. Using the ZFS snapshot feature I was able to make a snapshot of the file system holding the PostgreSQL database, write the snapshot to a compressed file, transfer it to another Ubuntu 14.04 LTS host running ubuntu-zfs, restore it, and launch PostgreSQL using that data directory with all the data (seemingly) intact.

The database is very low-traffic, so I do not know how effective this strategy would be for a busier database.

I take no responsibility if you attempt this setup and it causes data loss or other issues. Use it at your own risk; this document is meant to explain a potential setup and open discussion about limitations and potential improvements.

First Host Setup

/*
* robot.js
*
* You'll need three keys in order to unlock the
* Algorithm: the red key, the green key, and the
* blue key. Unfortunately, all three of them are
* behind human-proof barriers.
*
* The plan is simple: reprogram the maintenance
* robots to grab the key and bring it through
/*************
* ambush.js *
*************
*
* Oh. Oh, I see. This wasn't quite part of the plan.
*
* Looks like they won't let you take the Algorithm
* without a fight. You'll need to carefully weave your
* way through the guard drones.
*
/**********************
* fordingTheRiver.js *
**********************
*
* And there's the river. Fortunately, I was prepared for this.
* See the raft on the other side?
*
* Everything is going according to plan.
*/
/*************
* colors.js *
*************
*
* You're almost at the exit. You just need to get past this
* color lock.
*
* Changing your environment is no longer enough. You must
* learn to change yourself. I've sent you a little something
* that should help with that.
@xor-gate
xor-gate / MailinatorAliases
Created March 13, 2020 15:00 — forked from nocturnalgeek/MailinatorAliases
A list of alternate domains that point to @mailinator.com
@binkmail.com
@bobmail.info
@chammy.info
@devnullmail.com
@letthemeatspam.com
@mailinater.com
@mailinator.net
@mailinator2.com
@notmailinator.com
@reallymymail.com

This is an outdated draft that was used to review the content with FreeBSD contributors. For the latest revision, vist http://shawndebnath.com/articles/2016/03/27/freebsd-jails-with-vlan-howto.html.


FreeBSD Jails with VLAN HOWTO

This article discusses how to set up jails on a FreeBSD 11-CURRENT system utilizing VIMAGE (aka VNET) to provide a virtualized independent network stack for each jail with support for VLAN tagging.

Prerequisites

@xor-gate
xor-gate / Jenkinsfile
Created October 2, 2019 12:30 — forked from merikan/Jenkinsfile
Some Jenkinsfile examples
Some Jenkinsfile examples