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 | |
# $Id: tinyback.sh 33 2007-05-02 14:18:50Z damonp $ | |
# | |
# Shell script to create backup of a list of files | |
# | |
# Copyright (c) 2007 Damon Parker < damonp@damonparker.org > | |
# Licensed under the GNU GPL. See http://www.gnu.org/licenses/gpl.html | |
# This script is not supported in any way. Use at your own risk. |
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
#### | |
# | |
# Builds unbuntu/trusty64 box and installs Nancy/Mono and requirements. | |
# https://github.com/NancyFx/Nancy | |
# | |
#### |
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/sh | |
ansible-playbook ~/bin/deploy_git.yml --extra-vars="hosts=ANSIBLE_HOST_GROUP project=PROJECT releasedir=SRV_RELASE_PATH repo=ssh://git@github.com/damonp/PROJECT.git" |
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 | |
# Simple script to check open ports on a remote host and restart via ssh/ansible if down. | |
# Assumes using unique hostnames configured in /etc/ansible/hosts | |
# | |
if [ "$1" = "" ]; then | |
echo "Host and port(s) to check required." | |
echo "`basename $0` <hostname> <portlist>" | |
echo "`basename $0` host.domain.com 22,80,443,8080" | |
exit; |
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 | |
if [ "$1" = "" ]; then | |
echo Current branch name required | |
exit; | |
fi | |
if [ "$2" = "stash" ]; then | |
echo "Stashing current state..." | |
git stash |
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 | |
# $Id: tunnel_bitcoind.sh 13-Oct-14 16:02:39 $ | |
# | |
# Shell script to create ssh port forwarded tunnel to remote server for | |
# localhost bitcoind rpc access. | |
# | |
# This script is not supported in any way. Use at your own risk. | |
# |
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
<!-- | |
Credit: http://www.jonathantneal.com/blog/the-html5-invoice/ | |
Rolled into single file for transportability. | |
--> | |
<!doctype html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>Invoice: #</title> | |
<style> |
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
--- | |
# file: deploy_git.yml | |
- | |
hosts: "{{ hosts }}" | |
user: root | |
vars: | |
- project: "{{ project }}" | |
- repo: "{{ repo }}" | |
- releasedir: "{{ releasedir }}" | |
- run_composer: "{{ composer | default(false) }}" |
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
--- | |
# ^^^ YAML documents must begin with the document separator "---" | |
# | |
#### Example docblock, I like to put a descriptive comment at the top of my | |
#### playbooks. | |
# | |
# Overview: Playbook to bootstrap a new host for configuration management. | |
# Applies to: production | |
# Description: | |
# Ensures that a host is configured for management with Ansible. |
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
# http://codex.wordpress.org/Nginx | |
# nginx.conf | |
# Generic startup file. | |
user {user} {group}; | |
#ususally equal to number of CPU's you have. run command "grep processor /proc/cpuinfo | wc -l" to find it | |
worker_processes 2; | |
error_log /var/log/nginx/error.log; |
NewerOlder