Skip to content

Instantly share code, notes, and snippets.

View m1ch4ls's full-sized avatar

Michal Skvely m1ch4ls

  • Prague
View GitHub Profile
#!/usr/bin/env bash
DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
alias ls=/bin/ls
function cleanup() {
rm -f /tmp/$$
}
function die() {
@m1ch4ls
m1ch4ls / nginx
Created February 26, 2015 10:56
Nginx init script
#!/bin/sh
### BEGIN INIT INFO
# Provides: nginx
# Required-Start: $local_fs $remote_fs $network $syslog $named
# Required-Stop: $local_fs $remote_fs $network $syslog $named
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: starts the nginx web server
# Description: starts nginx using start-stop-daemon
@m1ch4ls
m1ch4ls / nginx_build.sh
Created February 20, 2015 10:29
Building Nginx for Lindat
#!/bin/bash
NGINX_VERSION=1.6.2
DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
pushd $DIR
function download_archive {
local dirname=$1
local url=$2