Skip to content

Instantly share code, notes, and snippets.

View deanet's full-sized avatar
:octocat:
talk is cheap, show me the code

deanetdavid deanet

:octocat:
talk is cheap, show me the code
View GitHub Profile
# basic pfctl control
# ==
# Related: http://www.OpenBSD.org
# Last update: Tue Dec 28, 2004
# ==
# Note:
# this document is only provided as a basic overview
# for some common pfctl commands and is by no means
# a replacement for the pfctl and pf manual pages.
@deanet
deanet / kickstart-for-pxeboot-coreos
Created January 16, 2018 01:57 — forked from uzyexe/kickstart-for-pxeboot-coreos
Kickstart default PXElinux for coreos
default coreos
prompt 1
timeout 15
display boot.msg
label coreos
menu default
kernel http://<your_server_name>/coreos_production_pxe.vmlinuz
append initrd=http://<your_server_name>/coreos_production_pxe_image.cpio.gz cloud-config-url=http://<your_server_name>/cloud-config.yml
#!/bin/bash
# Copyright (C) 2012 Crowd9 Pty Ltd
usage ()
{
echo >&2 "usage: bash $0 'john@example.com' 'MyBox' 'MyProvider.com' [\\\$20/mth]"
}
if [ $# -lt 3 ]
then
@deanet
deanet / docker-ssl-deployment.sh
Created October 17, 2017 08:01 — forked from jshimko/docker-ssl-deployment.sh
Deploy Reaction Commerce on Digital Ocean with Nginx and a Let's Encrypt SSL certificate
# start a server on Digital Ocean
# https://docs.docker.com/machine/drivers/digital-ocean/
docker-machine create \
--driver digitalocean \
--digitalocean-access-token <YOUR API KEY> \
--digitalocean-size 2gb \
reaction
# tell Docker to run commands on that server
@deanet
deanet / install-gcc48-linuxbrew-centos6.md
Created July 22, 2016 06:05 — forked from stephenturner/install-gcc48-linuxbrew-centos6.md
Installing gcc 4.8 and Linuxbrew on CentOS 6

Installing gcc 4.8 and Linuxbrew on CentOS 6

The GCC distributed with CentOS 6 is 4.4.7, which is pretty outdated. I'd like to use gcc 4.8+. Also, when trying to install Linuxbrew you run into a dependency loop where Homebrew's gcc depends on zlib, which depends on gcc. Here's how I solved the problem.

Note: Requires sudo privileges.

Resources:

<?php
/**
* Easiest to use composer to install google-api-php-client and generate autoloader
* If you dont want to use composer you can manually include any needed files
*/
include_once 'vendor/autoload.php';
/**
* Client ID from https://console.developers.google.com/
* Must be added in Google Apps Admin console under Security -> Advanced -> Manage API client access
# force HTTP to HTTPS - /etc/nginx/conf.d/nonssl.conf
server {
listen 80;
server_name jira.example.com;
access_log off;
return 301 https://$server_name$request_uri;
}
# /etc/nginx/conf.d/jira.conf
server {
@deanet
deanet / rc.d
Last active August 29, 2015 14:04 — forked from jippi/rc.d
update-rc.d logstash-shipper defaults
update-rc.d logstash-reader defaults
#example vhost protect wp-login.php at nginx php-fpm
upstream arraudhah {
server unix:/var/run/php5-fpm.sock;
}
server {
listen 80;
server_name ar-raudhah.info www.ar-raudhah.info;
server_name_in_redirect off;