This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# disable all acpi wakeups except the power button | |
cat /proc/acpi/wakeup | grep enabled | grep -v PWRB | | |
while read dev foo | |
do | |
echo $dev > /proc/acpi/wakeup | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
URL_BASE="http://livestream.com/internetsociety" #"/hopeconf" | |
VIDEO_TYPE="progressive_url" | |
dump_track(){ | |
wget -O - "http://livestream.com/internetsociety${1}/hopeconf" 2>/dev/null| sed 's/","/",\n"/g' | grep $VIDEO_TYPE | grep -v smil | sed 's/[",]\+$//;s/.*"//' | grep http | |
} | |
for url in $(dump_track | tee lamarr); do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/bash | |
# vim: tabstop=2:softtabstop=2:shiftwidth=2:noexpandtab | |
# | |
# Authored by Yazz D. Atlas <[email protected]> | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); you may | |
# not use this file except in compliance with the License. You may obtain | |
# a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ecdsa-sha2-nistp521 AAAAE2VjZHNhLXNoYTItbmlzdHA1MjEAAAAIbmlzdHA1MjEAAACFBADfkf+IoIighmFoYFaCQopaOQyRoE0B5eiJ6gKLUbJdTxxaxAq8y1bIj2XWAk8Uy/uqWUdOVAvcOkwUGBMBH5YZRAFcMNZk5QbUOSpZyC2sr0yKxZsshjqnUyZIifIQp1ydwE73N8CkH+FhKIGyeNE/x3jI7xXsePNoL/H2GKNzri0peA== jesusaurus@avalon |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -o errexit | |
# Author: David Underhill | |
# Script to permanently delete files/folders from your git repository. To use | |
# it, cd to your repository's root and then run the script with a list of paths | |
# you want to delete, e.g., git-purge path1 path2 | |
if [ $# -eq 0 ]; then | |
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import restclient | |
import json | |
import os | |
class ident(object): | |
def __init__(self, region_url, debug=False): | |
self.debug = debug | |
self.connect(url=region_url) | |
def __enter__(self): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import logging | |
logging.basicConfig(format='%(asctime)s\t%(name)-16s %(levelname)-8s %(message)s') | |
#very noisy library | |
requests_log = logging.getLogger("requests") | |
requests_log.setLevel(logging.WARNING) | |
logger = logging.getLogger('es_migrate') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
$SALT_HOME=/var/local/salt | |
sudo useradd -m -d $SALT_HOME -r -U -c "Salt Master Daemon" salt | |
mkdir salt | |
cat > salt/master <<EOF | |
user: salt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% macro proxy(site, server, port, http=True, https=False) -%} | |
extend: | |
{{ pillar['package']['apache'] }}: | |
service: | |
- watch: | |
- file: /etc/{{ pillar['package']['apache'] }}/sites-enabled/{{ site }} | |
/etc/{{ pillar['package']['apache'] }}/sites-enabled/{{ site }}: | |
file.managed: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# The pattern `exec > $X 2>&1` does two things: the last bit redirects standard | |
# error to go to standard output, and the first bit sends standard output to the | |
# file $X. Here our $X is the process substitution `>( $process )` which takes | |
# the standard input of $process and presents it as a file handle. Putting | |
# these two together, we have both our standard out and our standard error | |
# going to the standard input of $process. Our $process here first runs tee, | |
# which sends its standard input to both standard out and to the file listed. | |
# We then pipe our standard out into the logger command, which sends it to syslog. |
NewerOlder