Skip to content

Instantly share code, notes, and snippets.

View nzajt's full-sized avatar

nate daily nzajt

View GitHub Profile
@nzajt
nzajt / magenot-host.conf
Created July 2, 2014 22:03
Magento Nginx host file
server {
listen 80 default;
listen 443 ssl;
ssl_certificate PATHTOSSL.crt;
ssl_certificate_key PATHTOSSL.key;
server_name www.SITEURL.com *.SITEURL.com; ## Domain is here twice so server_name_in_redirect will favour the www
root PATH TO MAGENTO ROOT;
autoindex off;
@nzajt
nzajt / speed_test_two_fer.rb
Last active August 20, 2018 23:21
Testing if a module or class is faster when only using one method. requires gem 'benchmark-ips' from https://github.com/evanphx/benchmark-ips
require 'benchmark/ips'
# test for modules
module TwoFer
# Takes name or no name and returns statement
def self.two_fer(name = 'you')
"One for #{name}, one for me."
end
end
@nzajt
nzajt / gist:cfe7c5514ed662adda4b
Last active February 2, 2016 08:35
Magento on osx Mavricks with nginx, php-fmp

#Magento on osx Mavricks with nginx, php-fmp

##Step 1

###Make sure that brew is up to date and installed.

If you do not have home brew installed, go to the link below and install it.

@nzajt
nzajt / gist:8466723
Created January 17, 2014 01:12
Ubuntu vsftpd.conf -- For Passive ftp. Good for them Gui Clients.
# Example config file /etc/vsftpd.conf
#
# The default compiled in settings are fairly paranoid. This sample file
# loosens things up a bit, to make the ftp daemon more usable.
# Please see vsftpd.conf.5 for all compiled in defaults.
#
# READ THIS: This example file is NOT an exhaustive list of vsftpd options.
# Please read the vsftpd.conf.5 manual page to get a full idea of vsftpd's
# capabilities.
#
@nzajt
nzajt / gist:6271093
Last active December 21, 2015 07:28
Vagrant Up
vagrant init ubuntu http://cloud-images.ubuntu.com/precise/current/precise-server-cloudimg-vagrant-amd64-disk1.box
vagrant up
@nzajt
nzajt / magento-startup.sh
Last active December 17, 2015 19:49
Magento Startup Ununtu
#!/usr/bin/env bash
apt-get update
apt-get install -y apache2
apt-get install php5 php5-curl php5-gd php5-mcrypt php5-mysql php5-xsl -y
apt-get install vim -y
apt-get install git -y
apt-get install s3cmd -y
apt-get install zsh
wget –no-check-certificate https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O – | sh
@nzajt
nzajt / bootstrap-chef.sh
Created March 15, 2013 22:50
Get chef-solo up and going
# ---------------------------------------------
# Chef Folders
# ---------------------------------------------
mkdir /var/chef
cd /var/chef
mkdir -p cookbooks/main/recipes
# --------------------------------------------------------
# Update It
#---------------------------------------------------------
sudo yum -y update
# --------------------------------------------------------
# Packages
# --------------------------------------------------------
@nzajt
nzajt / Sass Bootstrap Variables
Created November 13, 2012 18:26
A good list of SASS variables for those using SASS with Boostrap
//
// Variables
// --------------------------------------------------
// Global values
// --------------------------------------------------
// Grays
echo "Started"
brew tap homebrew/dupes
brew tap homebrew/versions
brew tap homebrew/homebrew-php
brew update
brew install --without-apache --with-fpm --with-mysql --whith-mcrypt php55
brew install nginx mariadb
echo "done"