Skip to content

Instantly share code, notes, and snippets.

View alejandrobernardis's full-sized avatar
🐻

Alejandro M. BERNARDIS alejandrobernardis

🐻
View GitHub Profile
@alejandrobernardis
alejandrobernardis / 10gen.repo.x86_64
Created February 14, 2013 18:20
10gen.repo.x86_64
[10gen]
name=10gen Repository
baseurl=http://downloads-distro.mongodb.org/repo/redhat/os/x86_64
gpgcheck=0
@alejandrobernardis
alejandrobernardis / nginx.repo
Created February 14, 2013 18:21
nginx.repo
[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/centos/6/$basearch/
gpgcheck=0
enabled=1
@alejandrobernardis
alejandrobernardis / bash_profile
Created February 14, 2013 18:23
bash_profile
# ((ak)) config
export HISTCONTROL=ignoredups:ignorespace
export HISTSIZE=5000
export HISTFILESIZE=1000
export HISTIGNORE="ls:cd:[bf]g:exit:..:...:l:l.:ll:la:h:history:edit-profile:reload-profile"
# ((ak)) helpers
alias l='ls -l';
alias l.='ls -d .*'
alias ll='ls -Al';
@alejandrobernardis
alejandrobernardis / supervisord.conf
Created February 14, 2013 18:24
supervisord.conf
[include]
files = /etc/supervisord/*.supervisor
[supervisord]
directory = /etc/supervisord
pidfile = /var/run/supervisord.pid
childlogdir = /var/log/supervisord
logfile = /var/log/supervisord/supervisord.log
logfile_maxbytes = 50MB
logfile_backups = 10
@alejandrobernardis
alejandrobernardis / supervisord
Created February 14, 2013 18:25
supervisord
#!/bin/sh
# /etc/rc.d/init.d/supervisord
#
# Supervisor is a client/server system that
# allows its users to monitor and control a
# number of processes on UNIX-like operating
# systems.
#
# chkconfig: 345 83 04
#
@alejandrobernardis
alejandrobernardis / mongod.conf
Created February 14, 2013 18:32
mongod.conf
# mongo.conf
logpath=/var/log/mongo/mongod.log
logappend=true
fork=true
dbpath=/var/lib/mongo
auth=true
bind_ip=127.0.0.1
rest=false
nohttpinterface=true
@alejandrobernardis
alejandrobernardis / ngxadd.py
Last active December 13, 2015 19:48
NGINX, Add Site
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (c) 2013 Asumi Kamikaze Inc.
# Copyright (c) 2013 The Octopus Apps Inc.
# Licensed under the Apache License, Version 2.0 (the "License")
#
# Author: Alejandro M. Bernardis
# Email: alejandro.m.bernardis at gmail.com
# Created: 2/114/13, 12:32 AM
@alejandrobernardis
alejandrobernardis / ssh.py
Created February 16, 2013 16:10
ssh.py // Bill Scheel <LinuxRockz@gmail.com>
#!/usr/bin/env python
# Mysshkey
# Version 0.0.3
# Bill Scheel <LinuxRockz@gmail.com>
# January 1, 2007
# Released under the GPL License- http://www.fsf.org/licensing/licenses/gpl.txt
#
import sys, string, glob, os, re, exceptions, traceback, pxssh, pexpect, getpass
# System Functions Do Not Touch
class ValidateMethod(object):
def __init__(self, *args, **kwargs):
self._args = args or []
self._kwargs = kwargs or {}
def __call__(self, method):
def wrap(context):
assert isinstance(context, ValidateMethod)
def wrapper(self, *args, **kwargs):
@alejandrobernardis
alejandrobernardis / MANIFEST
Last active December 15, 2015 08:39
Py | Makefile
include tox.ini, setup.py
recursive-include tests *