Skip to content

Instantly share code, notes, and snippets.

View trinitronx's full-sized avatar
⛩️
Zazen

James Cuzella trinitronx

⛩️
Zazen
View GitHub Profile
@davidlu1001
davidlu1001 / terraform_include_exclude
Last active November 24, 2021 16:35
Makefile for Terraform to support include/exclude
PLAN_OPTIONS ?=
APPLY_OPTIONS ?=
EXCLUDE ?=
INCLUDE ?=
# For Terraform 0.12 (using `-no-color` to avoid dealing with terminal color)
define PLAN_OPTIONS_EXCLUDE
$(shell terraform show -no-color current.plan | perl -nle 'if (/\s# (.*?)\s/) {print $$1}' | grep -E -v '$(1)' | sed -e 's/^/-target="/g' -e 's/$$/"/g' | xargs)
endef
@kevinoid
kevinoid / .bashrc
Created July 31, 2019 16:31
GnuPG pinentry script for terminal or graphical interface based on $PINENTRY_USER_DATA.
# ~/.bashrc: executed by bash(1) for non-login shells.
# If file exists (likely) copy fragment below into existing script:
# If stdin is a terminal
if [ -t 0 ]; then
# Set GPG_TTY so gpg-agent knows where to prompt. See gpg-agent(1)
export GPG_TTY="$(tty)"
# Set PINENTRY_USER_DATA so pinentry-auto knows to present a text UI.
export PINENTRY_USER_DATA=USE_TTY=1
@SabrinaMarkon
SabrinaMarkon / index.html
Last active November 9, 2021 11:28
Three.js Custom AxisHelper Axis Arrows - https://jsbin.com/vaqudin
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript" src="https://getfirebug.com/firebug-lite-debug.js"></script>
<meta name="description" content="Three.js Custom AxisHelper Axis Arrows" />
<meta charset="utf-8" />
<title>Three.js Custom AxisHelper Axis Arrows</title>
<style>
#container {
background: #000000;
@tomgross
tomgross / README.md
Last active August 6, 2024 07:39
Homebrew Cask for installing pCloud on a Mac

Installing pCloud with Homebrew Cask

Since this recipe was rejected because of the volatile nature of pCloud links (see homebrew-cask#57634) I try to maintain this myself because it is useful to me and might be for others.

  • Download pcloud-drive.rb.
  • Run brew cask install pcloud-drive.rb.

To uninstall run brew cask uninstall pcloud-drive.rb.

@bigbes
bigbes / How-to-automate-build-bottles-your-homebrew-tap.md
Created September 7, 2018 12:52 — forked from maelvls/How-to-automate-build-bottles-your-homebrew-tap.md
Tutorial on how to automate the build of bottles on your Homebrew tap (linux/mac)

How to automate the build of bottles on your Homebrew tap

This tutorial is a follow-up to the discussion we had on davidchall/homebrew-hep#114. It relies on a fork of the test-bot provided by davidchall; you can get it with brew tap maelvalais/test-bot. First:

  1. the Github project must be of the form https://github.com/<user>/homebrew-<tap> with the following tree (I give the example of one of my formulas, touist):
@steven2358
steven2358 / ffmpeg.md
Last active April 21, 2025 02:17
FFmpeg cheat sheet
@z1nkum
z1nkum / graphite-grafana-statsd-inside-docker.md
Last active May 10, 2023 08:43
Run graphite-stack inside docker via docker-compose
# getenforce
Disabled

Also we need docker, docker-compose, certbot (if you need LetEncrypt)

mkdir -p /opt/graphite/conf /opt/graphite/data /opt/graphite/storage /opt/statsd /opt/grafana/log

/etc/docker/compose/graphite/docker-compose.yml

@ansemjo
ansemjo / ssh-auth-sock.service
Last active August 8, 2024 22:43 — forked from xenithorb/ssh-auth-sock.service
systemd user unit to set SSH_AUTH_SOCK variable for X11/Wayland/GNOME and make it work with GnuPG agent
# Place this file in ~/.config/systemd/user/ssh-auth-sock.service
# $ systemctl --user daemon-reload
# $ systemctl --user enable --now ssh-auth-sock.service
# Add 'echo UPDATESTARTUPTTY | gpg-connect-agent >/dev/null' in your ~/.bashrc.
# Logout or reboot.
[Unit]
Description=Set SSH_AUTH_SOCK to GnuPG agent
[Service]
@kafene
kafene / gpg-wkd.md
Last active February 13, 2025 21:46
Setting up WKD for self-hosted automatic key discovery

I just got this working so I figured I'd share what I found, since there's hardly any information about this anywhere online except an RFC, the GPG mailing list and one tutorial from the GnuPG blog.

You can use automatic key discovery with WKD (Web key directory) to make it easy for users to import your key, in GPG since version 2.1.12. Since this feature is fairly new, it isn't yet available in the current LTS release of Ubuntu (16.04; xenial), however it is available in Debian stable (stretch).

I couldn't add a DNS CERT or DANE / OPENPGPKEY record through my email service (which also hosts my nameservers). I tried making the PKA record - a foo._pka.example.com TXT record but GPG doesn't seem to recognize it and fails; I'm still investigating why.

So the last option for self-hosted auto-discovery was WKD.

First thing I had to do was add an email address to my key. My primary UID is just my name so the key represents my identity rather