Skip to content

Instantly share code, notes, and snippets.

Avatar
🐈
Fighting the absurd every day

Giovanni Tirloni gtirloni

🐈
Fighting the absurd every day
View GitHub Profile
View terraform.yml
name: Terraform
on:
workflow_dispatch:
push:
branches:
- main
paths:
- 'terraform-aws/**'
@gtirloni
gtirloni / ghactions-roadmap.txt
Last active Jul 28, 2020
GH Actions - Interesting work in progress
View ghactions-roadmap.txt
https://github.com/github/roadmap/issues/51
https://github.com/github/roadmap/issues/52
https://github.com/github/roadmap/issues/59
https://github.com/github/roadmap/issues/75
https://github.com/github/roadmap/issues/78
https://github.com/github/roadmap/issues/88
https://github.com/github/roadmap/issues/96
https://github.com/github/roadmap/issues/98
https://github.com/github/roadmap/issues/99
@gtirloni
gtirloni / docker-compose.yml
Created Jun 6, 2019
Kubernetes-like docker-compose networking
View docker-compose.yml
version: '3.7'
services:
# All containers share a single network namespace (like in Kubernetes pods)
# Port forwarding is done in the base container, the only one with a network namespace of its own
base:
image: busybox
command: 'sh -c "trap : TERM INT; tail -f /dev/null & wait"' # keep container running forever
ports:
View vagrant-up.txt
$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'inclusivedesign/fedora27'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'inclusivedesign/fedora27' is up to date...
==> default: A newer version of the box 'inclusivedesign/fedora27' for provider 'virtualbox' is
==> default: available! You currently have version '20180704'. The latest is version
==> default: '20180723'. Run `vagrant box update` to update.
==> default: Setting the name of the VM: f27_default_1532375676457_75421
==> default: Fixed port collision for 22 => 2222. Now on port 2200.
@gtirloni
gtirloni / mirror.sh
Created Jul 18, 2018
CentOS/Fedora mirror
View mirror.sh
#!/usr/bin/env bash
set -o errexit
set -o pipefail
set -o xtrace
LOCKFILE="${PWD}/$(basename "$0").lock"
LOCKFD=99
_lock() { flock -"$1" "$LOCKFD"; }
View lfs258.md

etcd

List all keys

ETCDCTL_API=3 etcdctl get / --prefix --keys-only

What used to be directories in etcd v2

ETCDCTL_API=3 etcdctl get / --prefix --keys-only | awk -F/ '{ printf("%s/%s\n", $2, $3); }'| sort | uniq

@gtirloni
gtirloni / Vagrantfile
Created Aug 5, 2017
Vagrantfile multi-VM
View Vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
$controller_count = 3
$worker_count = 3
Vagrant.configure("2") do |config|
config.vm.box = "centos/7"
config.vm.provider "virtualbox" do |vb|
@gtirloni
gtirloni / npm_cache.md
Last active Jul 8, 2017
Comparing local-npm and npm caching
View npm_cache.md

Method

git clone https://github.com/GPII/universal
rm -rf node_modules
time npm install

npm 3.10.10

  • Run #1 - 3m3s (cold cache)
View keybase.md

Keybase proof

I hereby claim:

  • I am gtirloni on github.
  • I am gtirloni (https://keybase.io/gtirloni) on keybase.
  • I have a public key ASBDIREBYGOYwlFRJTqa6hyyiq_zFN5-4r1okvZzXc128wo

To claim this, I am signing this object:

@gtirloni
gtirloni / .vagrant.yml
Last active Jul 19, 2017
F2F DevOps - Vagrant Kasper's PR
View .vagrant.yml
env:
vms:
server:
box: inclusivedesign/fedora26
cpu: 2
memory: 2048
stages:
- cleanup
- build