This file contains hidden or 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 | |
| #-*-coding:utf-8-*- | |
| import urllib, json , os | |
| from shutil import rmtree | |
| url = 'http://yourjenkinsbaseurl/api/python?pretty=true' | |
| jenkins_workspace_path = '/var/lib/jenkins/workspaces/' | |
| data = eval(urllib.urlopen(url).read()) | |
| jobnames = [] |
This file contains hidden or 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 | |
| # As root ( via `sudo su -` ): | |
| # Initialize ephemeral storage | |
| curl https://gist.githubusercontent.com/fsultan/9936494/raw/ephemeral > /etc/init.d/ephemeral | |
| chmod +x /etc/init.d/ephemeral | |
| ln -s ../init.d/ephemeral /etc/rcS.d/S10ephemeral | |
| /etc/init.d/ephemeral | |
| ln -s /mnt/jenkins /var/jenkins | |
| #ln -s /mnt/mongodb /var/lib/mongodb |
This file contains hidden or 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 | |
| # -*- coding: utf-8 | |
| import ConfigParser | |
| import argparse | |
| import getpass | |
| import os | |
| import shlex | |
| import subprocess | |
| import sys |
This file contains hidden or 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 | |
| import subprocess | |
| #import argparse | |
| import sys | |
| from time import sleep | |
| #parser = argparse.ArgumentParser(description='Build script for creating VM and running tests against it.') | |
| #parser.add_argument('user', metavar='U', type=str, nargs='+', | |
| # help='The user of the hostmachine. Required to create the VM through SSH.') | |
| #parser.add_argument('host', metavar='H', type=str, nargs='+', |
This file contains hidden or 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
| ; Sample supervisor config file. | |
| [unix_http_server] | |
| file=/tmp/supervisor.sock ; (the path to the socket file) | |
| ;chmod=0700 ; sockef file mode (default 0700) | |
| ;chown=nobody:nogroup ; socket file uid:gid owner | |
| ;username=user ; (default is no username (open server)) | |
| ;password=123 ; (default is no password (open server)) | |
| ;[inet_http_server] ; inet (TCP) server disabled by default |
This file contains hidden or 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
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |
This file contains hidden or 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
| # -*- coding: utf-8 -*- | |
| """MyCompany Fabric script. | |
| * Deploy code | |
| * Set up a local development environment | |
| There are two ways to deploy the myrepo code: | |
| 1. :func:`deploy` will do a full virtualenv installation/update and expand a | |
| tarball of the specified git revision (defaults to HEAD) to a timestamped |
This file contains hidden or 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 | |
| #OpenVPN Installer for Centos 5 & 6 | |
| #Prequisites | |
| #Known issues Centos 6 isnt currently working due to ca.crt error | |
| #Written by Onessa credits to Keith from SaveSrv.net for tutorial I used as base Original Tutorial > https://safesrv.net/install-openvpn-on-centos/ | |
| if [ $USER != 'root' ] | |
| then | |
| echo "REQUIRES ROOT" | |
| exit 0 | |
| fi |
This file contains hidden or 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 | |
| el_version="6" | |
| kernel_major="2.6.32" | |
| kernel_minor="279.5.1" | |
| vz_major="042stab061" | |
| vz_minor=".2" | |
| echo "Fetching OpenVZ Repo..." | |
| cd /etc/yum.repos.d |
This file contains hidden or 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 | |
| #network param | |
| IP=94.23.251.96 | |
| elastic=10.0.0.1 | |
| test=10.0.0.2 | |
| #nat param 'VMip,source_port,destination_port' | |
| rules_nat+=("$elastic,1021,22") | |
| rules_nat+=("$elastic,9200,9200") |