Skip to content

Instantly share code, notes, and snippets.

View garethtdavies's full-sized avatar

Gareth Davies garethtdavies

View GitHub Profile
@garethtdavies
garethtdavies / promtail_docker_logs.md
Created February 4, 2021 05:19 — forked from ruanbekker/promtail_docker_logs.md
Docker Container Logging using Promtail

Here are the instructions for creating your own multi-node network on your local machine:

Run the following commands on Debian9

  1. sudo apt-get install -y curl make bubblewrap pkg-config postgresql m4 libgmp-dev libffi-dev libjemalloc-dev libpq-dev libssl-dev libsodium-dev cargo lib32z1-dev python3 python3-pip git unzip libbz2-dev psmisc apt-transport-https ca-certificates curl software-properties-common gnupg2 bc
  2. curl -fsSL https://download.docker.com/linux/debian/gpg | sudo apt-key add -
  3. sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/debian $(lsb_release -cs) stable"
  4. sudo apt update
  5. sudo apt install -y docker-ce
  6. sudo usermod -aG docker ${USER}
@garethtdavies
garethtdavies / Bash_command_line_shortcuts.md
Created November 12, 2018 21:00 — forked from P7h/Bash_command_line_shortcuts.md
Bash command line Shortcuts

Bash command line Shortcuts

Picked these from here

Command Editing Shortcuts

Command Note
Ctrl + a go to the start of the command line
Ctrl + e go to the end of the command line
Ctrl + k delete from cursor to the end of the command line
@garethtdavies
garethtdavies / zecSaplingMultiSig.js
Created October 25, 2018 01:18 — forked from argjv/zecSaplingMultiSig.js
Using bitgo-utxo-lib to create a multisig Zcash Sapling compatible transaction
const bitGoUTXO = require('bitgo-utxo-lib');
// Choose the configuration for the transaction builder
const zecTestNetwork = bitGoUTXO.networks.zcashTest;
const builder = new bitGoUTXO.TransactionBuilder(zecTestNetwork);
// Required Zcash parameters
builder.setVersion(bitGoUTXO.Transaction.ZCASH_SAPLING_VERSION); // 4
builder.setVersionGroupId(parseInt('0x892F2085', 16));
@garethtdavies
garethtdavies / 0_reuse_code.js
Last active August 29, 2015 14:22
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
<!doctype html>
<!-- paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ -->
<!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en"> <![endif]-->
<!--[if IE 7]> <html class="no-js ie7 oldie" lang="en"> <![endif]-->
<!--[if IE 8]> <html class="no-js ie8 oldie" lang="en"> <![endif]-->
<!-- Consider adding an manifest.appcache: h5bp.com/d/Offline -->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
<head>
<meta charset="utf-8">