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
augeas { "ceph.conf": | |
lens => "Samba.lns", | |
incl => "/etc/ceph/ceph.conf", | |
changes => [ | |
"set target[. = '${name}'] '${name}'", | |
"set target[. = '${name}']/${key} '${value}'", | |
] | |
} |
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
cobbler_api = ServerProxy("http://cobbler/cobbler_api") | |
token = cobbler_api.login("USERNAME", "PASSWORD") | |
asset_list = ["server01", "server02"] | |
for system in asset_list: | |
print "Managing system %s" % system | |
print "System name is %s" % a | |
try: | |
handle = cobbler_api.get_system_handle(a, token) |
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/python | |
# | |
# Notes | |
# ----- | |
# This script depends on rtmpdump and mythnettv; specify their paths in the global variables below. | |
# If you don't need mythnettv support, leave it undefined (MYTHNETTV="") and the script will skip that step | |
# svn update -r275 # rtmpdump | |
# | |
import re,threading |
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 | |
#LOC=refs/remotes/origin | |
LOC=refs/heads | |
for branch in `git for-each-ref --format="%(refname)" $LOC`; do | |
found=$(git ls-tree -r --name-only $branch | grep "$1") | |
if [ $? -eq 0 ]; then | |
echo ${branch#$LOC/}: | |
for f in $found; 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
#!/usr/bin/ruby | |
# grid.rb | |
def find_grid(hostname) | |
grid = "admin" | |
if hostname =~ (/^(build|launch|util)\d{1,4}/) | |
grid = $1 | |
elsif hostname =~ (/^www\d{1,4}/) | |
grid = "web" | |
end |
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
for hb in `git branch -r | egrep -v "(modules|HEAD|>)" | cut -f2 -d/`; do for rm in `git branch -r | grep modules | cut -f3 -d/`; do r=`git rev-list -n1 remotes/origin/modules/$rm`; m=`git log --oneline remotes/origin/$hb -- modules/${rm}/manifests/init.pp | head -n1 | awk '{print $1}'`; if [[ -n "$m" ]]; then k=`git rev-list -n1 --parents $m | awk '{print $3}'`; if [[ "$r" != "$k" && -n "$k" ]]; then echo $hb $rm; git log --oneline $k..$r | while read z; do echo -n " $z"; echo; done; fi; fi; done; done |