Skip to content

Instantly share code, notes, and snippets.

Ken Prince kjprince

Block or report user

Report or block kjprince

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View NGiNX-Site.txt
# ------------------------------------------------------------------------
# REMOVE WWW PREFIX ------------------------------------------------------
# ------------------------------------------------------------------------
server {
server_name *.[sitename];
# remove all sub domains and www
rewrite ^/(.*)$ http://[sitename]/$1 permanent;
}
View NGiNX-Site.txt
# ------------------------------------------------------------------------
# REMOVE WWW PREFIX ------------------------------------------------------
# ------------------------------------------------------------------------
server {
server_name *.[sitename];
# remove all sub domains and www
rewrite ^/(.*)$ http://[sitename]/$1 permanent;
}
@kjprince
kjprince / Vagrantfile
Last active Aug 29, 2015
Vagrantfile for bootstrapping wordpress multi-site network
View Vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "jeter"
config.vm.box_url = "~/Downloads/debian-wheezy64.box"
@kjprince
kjprince / puppet_bootstrap.sh
Last active Aug 29, 2015
Bootstrap your puppet installation on a fresh box
View puppet_bootstrap.sh
#!/usr/bin/env bash
# Pre install script to install the a specific version of puppet
# If no parameter is supplied, the lastest version will be installed
# Thanks to: https://gist.github.com/dol/5776169
# Corresponds to Vagrantfile line
VERSION=""
if [ -n "$1" ]
then
VERSION="$1"
fi
@kjprince
kjprince / local-config.php
Created Mar 14, 2014
local-config.php for wordpress
View local-config.php
<?php
/*
This is a sample local-config.php file
In it, you *must* include the four main database defines
You may include other settings here that you only want enabled on your local development checkouts
This file should be ignored in your .gitignore file
*/
View test.md

Header 1

Overview {#overview}

Philosophy {#philosophy}

Markdown is intended to be as easy-to-read and easy-to-write as is feasible.

@kjprince
kjprince / backup-cron
Created Feb 17, 2015
Server Cron Job and Backup
View backup-cron
# ------------------------------------------------------------------------------
# SETUP CRON JOBS 4 Backup + Server Love ---------------------------------------
# ------------------------------------------------------------------------------
# Start by opening the default logger
nano /etc/rsyslog.d/50-default.conf
# Start tracking cron jobs
Uncomment: cron.* [remove the "#" around line 10]
Uncomment: daemon.* [remove the "#" around line 11]
View gist:44ba9fc36de13560454f
<p>This is a test to see if this strategy will work.</p>
<p>I'm going to see if I can add some inline links.</p>
<p><a href="http://princeagency.com" title="Hopewell Junction Insurance Agent" rel="follow">Hopewell Junction New York</a></p>
View gist:bad14742fd6fa0f82eec
Verifying that +kjprince is my openname (Bitcoin username). https://onename.com/kjprince
@kjprince
kjprince / wp-bootstrap-grid
Created Jun 19, 2015
3 Column Bootstrap Layout WP Posts
View wp-bootstrap-grid
<div class="container my-container">
<?php
$args=array(
'post_type' => 'reviews',
'post_status' => 'publish',
'posts_per_page' => 18
);
$my_query = null;
You can’t perform that action at this time.