Skip to content

Instantly share code, notes, and snippets.

@Videl
Videl / encrypted-zfs-nixos.org
Created June 20, 2021 11:41 — forked from mbbx6spp/encrypted-zfs-nixos.org
Encrypted ZFS for NixOS (WIP)

Encrypted ZFS for NixOS

Assumptions

We will have add one partition to a zpool.

You have the following set to appropriate values:

  • disk: the path for your disk device, e.g. /dev/sdb or /dev/nvme0
  • efi: the path for the EFI boot partition’s device, e.g. /dev/sdb1
  • part: the path to the partition of your root filesystem, e.g. /dev/sdb2
@Videl
Videl / my-admin-checker-mapper.js
Created August 15, 2020 11:59
JS for script mapper in Keycloak
// https://stackoverflow.com/questions/52518298/how-to-create-a-script-mapper-in-keycloak
// https://stackoverflow.com/questions/48199539/best-way-to-test-debug-javascript-mappers-policies-in-keycloak
// https://docs.oracle.com/javase/10/nashorn/nashorn-java-api.htm#JSNUG119
var client = keycloakSession.getContext().getClient();
var forEach = Array.prototype.forEach;
// print(user.getRealmRoleMappings());
var isAdmin = false;
provider "google" {
credentials = "${file("account.json")}"
project = "#####fill it out#####"
region = "europe-west1"
zone = "europe-west1-b"
}
resource "google_compute_firewall" "tsm-allow-dns" {
name = "firewall-dns"
network = "${google_compute_network.default.name}"
@Videl
Videl / attestation_sur_lhonneur.tex
Created September 4, 2014 12:00
Attestation sur l'honneur
\documentclass[12pt,a4paper]{article}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage[francais]{babel}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[left=2cm,right=2cm,top=3cm,bottom=2cm]{geometry}
\usepackage{multicol}
@Videl
Videl / gist:df750a3d5afb33259edb
Created July 24, 2014 09:01
Clean temporary Latex files
#!/bin/sh
find . -regex ".*\(aux\|bbl\|blg\|log\|nav\|out\|snm\|fls\|synctex\.gz\|fdb_latexmk\|toc\)$" -exec rm -i {} \;