jq is useful to slice, filter, map and transform structured json data.
brew install jq
""" | |
Copies all keys from the source Redis host to the destination Redis host. | |
Useful to migrate Redis instances where commands like SLAVEOF and MIGRATE are | |
restricted (e.g. on Amazon ElastiCache). | |
The script scans through the keyspace of the given database number and uses | |
a pipeline of DUMP and RESTORE commands to migrate the keys. | |
Requires Redis 2.8.0 or higher. |
# my_nat_cookbook/attributes/default.rb | |
# specify your CIDR in custom JSON somewhere: { "my_nat_cookbook": { "source_cidr": "10.1.0.0/16" } } | |
default[:deliv_nat][:source_cidr] = '0.0.0.0/0' | |
default[:deliv_nat][:aws_region] = node[:opsworks][:instance][:region] | |
default[:deliv_nat][:ec2_instance_id] = node[:opsworks][:instance][:aws_instance_id] |
I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!
\
#!/bin/sh | |
### | |
# SOME COMMANDS WILL NOT WORK ON macOS (Sierra or newer) | |
# For Sierra or newer, see https://github.com/mathiasbynens/dotfiles/blob/master/.macos | |
### | |
# Alot of these configs have been taken from the various places | |
# on the web, most from here | |
# https://github.com/mathiasbynens/dotfiles/blob/5b3c8418ed42d93af2e647dc9d122f25cc034871/.osx |
Wes Winham [email protected]
There are many tutorials floating around the web that almost get you a dynamic VPN in EC2. The goal of this tutorial is to be a one-stop-shop for this specific setup.
#!/usr/bin/env ruby -w | |
# brew-services(1) - Easily start and stop formulas via launchctl | |
# =============================================================== | |
# | |
# ## SYNOPSIS | |
# | |
# [<sudo>] `brew services` `list`<br> | |
# [<sudo>] `brew services` `restart` <formula><br> | |
# [<sudo>] `brew services` `start` <formula> [<plist>]<br> |
#!/usr/bin/python | |
# rtorrent_xmlrpc | |
# (c) 2011 Roger Que <[email protected]> | |
# | |
# Python module for interacting with rtorrent's XML-RPC interface | |
# directly over SCGI, instead of through an HTTP server intermediary. | |
# Inspired by Glenn Washburn's xmlrpc2scgi.py [1], but subclasses the | |
# built-in xmlrpclib classes so that it is compatible with features | |
# such as MultiCall objects. |