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
# DESCRIPTION | |
# This playbook can be used to add an encrypted a disk to a system to mount | |
# at boot. | |
# | |
# !!!!!!!!!!!!!! WARNING !!!!!!!!!!!!!! | |
# !!!!!!!!!!!!!! WARNING !!!!!!!!!!!!!! | |
# !!!!!!!!!!!!!! WARNING !!!!!!!!!!!!!! | |
# !!!!!!!!!!!!!! WARNING !!!!!!!!!!!!!! | |
# | |
# Improper use of this playbook can result in data loss. |
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
from __future__ import print_function | |
import argparse | |
import hashlib | |
import multiprocessing | |
import os | |
import random | |
import string | |
import subprocess | |
from errno import EEXIST |
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
function retry { | |
local attempt=1 | |
local command="${@}" | |
while [ $attempt -ne 10 ]; do | |
echo "(run $attempt/10) running $command" | |
$command | |
if [[ $? -eq 0 ]]; then | |
echo "(success) $command" | |
break |
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 os | |
os.environ.update( | |
PYFARM_DATABASE_URI="sqlite:///:memory:" | |
) | |
from pyfarm.master.application import db | |
for i in range(5): | |
# setUp | |
from pyfarm.models.agent import Agent |
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 python | |
import subprocess | |
import sys | |
from datetime import datetime, timedelta | |
import pyinotify | |
class OnWriteHandler(pyinotify.ProcessEvent): | |
DELAY = timedelta(seconds=5) |
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
diff -r aa1a71e0adf7 netifaces.c | |
--- a/netifaces.c Tue Jan 31 11:48:23 2012 +0000 | |
+++ b/netifaces.c Fri Sep 13 20:14:12 2013 -0400 | |
@@ -400,11 +400,14 @@ | |
static int | |
add_to_family (PyObject *result, int family, PyObject *dict) | |
{ | |
+ PyObject *py_family; | |
+ PyObject *list; | |
+ |
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 | |
function usage { | |
echo $1 | |
echo "usage: $0 <start> <end> <by> <renderer> <project_root> <scene>" | |
exit 1 | |
} | |
START_FRAME=$1 | |
END_FRAME=$2 |