Skip to content

Instantly share code, notes, and snippets.

View lusis's full-sized avatar

John E. Vincent lusis

View GitHub Profile
@lusis
lusis / openldap_passwd.py
Last active September 11, 2015 18:02 — forked from rca/openldap_passwd.py
Python hashing and test functions for user passwords stored in OpenLDAP.
#!/usr/bin/env python
"""
http://www.openldap.org/faq/data/cache/347.html
As seen working on Ubuntu 12.04 with OpenLDAP 2.4.28-1.1ubuntu4
Author: Roberto Aguilar <roberto@baremetal.io>
"""
import hashlib
import os
-- GithubAPI
-- @Author : Hyro Vitaly Protago
-- @Version : 1.0.0
--[[
INFOS :
- Cannot delete an anonymous gist
]]--
GithubAPI = {
#!/bin/bash
# Simple Ad Hoc SmartOS Setup Service
set -o xtrace
. /lib/svc/share/smf_include.sh
cd /
PATH=/usr/sbin:/usr/bin:/opt/custom/bin:/opt/custom/sbin; export PATH
#!/bin/bash
#
# kick_api.sh
#
# please set your host
address="http://[your management server]:8080"
# please set your api key
api_key="QVOObVBiTodKl5L0vPQFCCELsxbtEHHysXU42XTFFwhBHWWFV7GaiH5oJG0yHHsqFzCcgflH8Ee8Ttk4m_qJLQ"
# please set your secret key
secret_key="zTl4qQtSZPijMkNYgkX1lQh6QlEUXyjSKeXSPZQl2MJifzOBFhNDA5cQlfK7Ds5BFEM_ua_5ELMPL-z4JNJBIA"
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant::Config.run do |config|
config.vm.define 'shortbus' do |c|
c.vm.box = "opscode-centos-5.5"
c.vm.box_url = "http://opscode-vm.s3.amazonaws.com/vagrant/boxes/opscode-centos-5.5.box"
c.vm.network :hostonly, "192.168.93.93"
@lusis
lusis / graphTemplates.conf
Created June 27, 2012 18:07 — forked from mleinart/graphTemplates.conf
Solarized graph template for Graphite
[solarized-dark]
background = #002b36
foreground = #839496
majorLine = #fdf6e3
minorLine = #eee8d5
lineColors = #268bd2,#859900,#dc322f,#d33682,#db4b16,#b58900,#2aa198,#6c71c4
fontName = Sans
fontSize = 10
fontBold = False
fontItalic = False
@lusis
lusis / gh-like.css
Created May 30, 2012 16:53 — forked from somebox/gh-like.css
github markdown css+script with syntax highlighting. Works with http://markedapp.com
/*
Some simple Github-like styles, with syntax highlighting CSS via Pygments.
*/
body{
font-family: helvetica, arial, freesans, clean, sans-serif;
color: #333;
background-color: #fff;
border: none;
line-height: 1.5;
margin: 2em 3em;
input {
file {
path => ["/var/log/knewton/*/*.log"]
type => "knewton_logback"
}
}
filter {
grok {
type => "knewton_logback"
@lusis
lusis / gist:1725181
Created February 2, 2012 19:11 — forked from jgyllen/gist:839690
RabbitMQ+SSL with Ruby
# rabbitmq.config
[
{rabbit, [
{tcp_listeners,[{"127.0.0.1",5672}]},
{ssl_listeners, [{"127.0.0.1",5671}]},
{ssl_options, [{cacertfile,"/usr/local/etc/rabbitmq/ssl/testca/cacert.pem"},
{certfile,"/usr/local/etc/rabbitmq/ssl/server/cert.pem"},
{keyfile,"/usr/local/etc/rabbitmq/ssl/server/key.pem"},
{verify,verify_none},
{fail_if_no_peer_cert,false}]}
@lusis
lusis / jumpstart.rb
Created January 25, 2012 20:14 — forked from densone/jumpstart.rb
Jumpstart an Ubuntu Chef Server with Ruby
require 'rubygems'
require 'aws'
require 'net/ssh'
require 'net/http'
require 'logger'
def message_lines
2.times do |x|
puts "****************************************"
end