Skip to content

Instantly share code, notes, and snippets.

@djcode
djcode / README.md
Last active January 22, 2021 20:26
A simple vault backup script

vault_backup.rb

Introduction

A ruby script written in an afternoon to backup/export key/values from HashiCorp's Vault. It uses the Vault ruby client libraries, so make sure they are installed beforehand with 'gem install vault'.

Be careful with the data exported using this tool. Vault is designed to be secure, and this tool does bypass some (all) of that security. Use at your own risk and be aware of the consequences.

This script can export the data in an encrypted fashion, but should by no means be considered secure.

Features

Keybase proof

I hereby claim:

  • I am djcode on github.
  • I am djolly (https://keybase.io/djolly) on keybase.
  • I have a public key whose fingerprint is 475D 1FDA FBC2 58EB DDCB 1777 1C01 14FB B7F4 9591

To claim this, I am signing this object:

@djcode
djcode / rpi-hdmi.sh
Created July 25, 2016 16:50 — forked from AGWA/rpi-hdmi.sh
Enable and disable the HDMI port on the Raspberry Pi: `rpi-hdmi on` to turn on, `rpi-hdmi off` to turn off. X is properly reinitialized when re-enabling.
#!/bin/sh
# Enable and disable HDMI output on the Raspberry Pi
is_off ()
{
tvservice -s | grep "TV is off" >/dev/null
}
case $1 in