Skip to content

Instantly share code, notes, and snippets.

View isaqueprofeta's full-sized avatar
🎯
Focusing

Isaque Profeta isaqueprofeta

🎯
Focusing
View GitHub Profile
@bastman
bastman / docker-cleanup-resources.md
Created March 31, 2016 05:55
docker cleanup guide: containers, images, volumes, networks

Docker - How to cleanup (unused) resources

Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...

delete volumes

// see: https://github.com/chadoe/docker-cleanup-volumes

$ docker volume rm $(docker volume ls -qf dangling=true)

$ docker volume ls -qf dangling=true | xargs -r docker volume rm

@u0d7i
u0d7i / disable_vim_auto_visual_on_mouse.txt
Last active November 4, 2024 04:45
Disable vim automatic visual mode on mouse select
Disable vim automatic visual mode on mouse select
issue: :set mouse-=a
add to ~/.vimrc: set mouse-=a
my ~/.vimrc for preserving global defaults and only changing one option:
source $VIMRUNTIME/defaults.vim
set mouse-=a
@bsmartt13
bsmartt13 / gist:efa02c40ea12c09d9c3a
Created September 17, 2014 17:02
OTX IP Reputation download links (updated hourly)
https://reputation.alienvault.com/reputation.generic.gz
https://reputation.alienvault.com/reputation.generic
https://reputation.alienvault.com/reputation.data
https://reputation.alienvault.com/reputation.snort.gz
https://reputation.alienvault.com/reputation.snort
https://reputation.alienvault.com/reputation.iptables.gz
https://reputation.alienvault.com/reputation.iptables
https://reputation.alienvault.com/reputation.squid.gz
https://reputation.alienvault.com/reputation.squid
https://reputation.alienvault.com/reputation.unix.gz
@stuart-warren
stuart-warren / vagrant-shell-arguments.rb
Last active March 23, 2022 21:13
Vagrant shell provisioning with variable arguments. This example iterates through an object and passes its keys and values as parameters to a shell script http://docs.vagrantup.com/v2/provisioning/shell.html It also creates one node for each key, value pair
Vagrant.configure("2") do |config|
HADOOP_NODES = {'hd-master' => '192.168.40.10',
'hd-slave1' => '192.168.40.11',
'hd-slave2' => '192.168.40.12'}
HADOOP_NODES.each do |node_name, node_ip|
config.vm.provision :shell do |s|
s.inline = 'echo -e "$1\t$2" | sudo tee -a /etc/hosts'
s.args = "#{node_ip} #{node_name}"