Skip to content

Instantly share code, notes, and snippets.

@clstokes
clstokes / assume-role-policy.json
Last active September 1, 2022 20:15
Example: Terraform IAM Role
{
"Version": "2012-10-17",
"Statement": [
{
"Action": "sts:AssumeRole",
"Principal": {
"Service": "ec2.amazonaws.com"
},
"Effect": "Allow",
"Sid": ""
@j-mcnally
j-mcnally / upgrade_container.sh
Last active June 15, 2018 10:51
Container Reload Script
#!/bin/bash
docker pull user/myrepo && \
docker rm -f myapp && \
docker run -d -p 80:80 -e RAILS_ENV=production --env-file=/opt/utils/deps/web.envfile --name=myapp --link=postgres:postgres --link=redis:redis user/myrepo
@micahhausler
micahhausler / master.sh
Last active January 23, 2016 08:42
Docker Orca (0.4.0) Quickstart instructions
#!/bin/bash
#
# Requires docker-toolbox >= 1.9.0d
# https://github.com/docker/toolbox/releases
MACHINE_NAME="orcamaster"
docker-machine create -d virtualbox $MACHINE_NAME
eval $(docker-machine env $MACHINE_NAME)
@crummy
crummy / README.md
Created October 17, 2014 22:00
Sonos Now Playing

Description

A Dashing widget that searches for a Sonos device that is currently playing music, and displays Now Playing information and album artwork.

Utilises soffe's Sonos controller.

Dependencies

Please add the following lines to your gemfile:

@stuartleeks
stuartleeks / ImportAzureVmsIntoRdcMan.ps1
Last active February 24, 2017 15:43
PowerShell script to create a Remote Desktop Connection Manager configuration file for all Windows Azure Virtual Machines in a subscription.Requires Azure PowerShell cmdlets: http://www.windowsazure.com/en-us/documentation/articles/install-configure-powershell/. See this blog post for more info: http://blogs.msdn.com/b/stuartleeks/archive/2014/0…
$rdcmanName = "Azure VMs"
$outputFileName = Get-Location | Join-Path -ChildPath "AzureVMs.rdg"
$xml = [xml]'<?xml version="1.0" encoding="utf-8"?>
<RDCMan schemaVersion="1">
<version>2.2</version>
<file>
<properties>
<name>blog</name>
<expanded>True</expanded>
@saetia
saetia / gist:1623487
Last active July 26, 2025 16:29
Clean Install – OS X 10.11 El Capitan

OS X Preferences


most of these require logout/restart to take effect

# Enable character repeat on keydown
defaults write -g ApplePressAndHoldEnabled -bool false

# Set a shorter Delay until key repeat