We will install Larave 4.1 with PHP5.5 & Latest nginx on Ubuntu 12.04.3 x64.
apt-get update && apt-get upgrade
adduser [username]
usermod -aG sudo [username]
apt-get -y install git
| <IfModule mod_rewrite.c> | |
| RewriteEngine On | |
| # !IMPORTANT! Set your RewriteBase here and don't forget trailing and leading | |
| # slashes. | |
| # If your page resides at | |
| # http://www.example.com/mypage/test1 | |
| # then use | |
| # RewriteBase /mypage/test1/ | |
| RewriteBase / | |
| RewriteCond %{REQUEST_FILENAME} !-f |
| <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); | |
| class Guzzle | |
| { | |
| public function __construct() | |
| { | |
| require_once APPPATH . 'third_party/guzzle/autoloader.php'; |
| # Railscast | |
| http://railscasts.com/episodes/308-oh-my-zsh | |
| # Install Zsh | |
| sudo apt-get update && sudo apt-get install zsh | |
| # Install Oh-my-zsh | |
| wget –no-check-certificate https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O – | sh | |
| # Make ZSH default shell |
| require 'uri' | |
| require 'cgi' | |
| require 'net/https' | |
| require 'json' | |
| require 'oauth2_mac_client' | |
| # oauth2_mac_client gem at https://github.com/herestomwiththeweather/oauth2_mac_client | |
| # usage using this test class: | |
| # > client = OAuth2Client.new | |
| # > client.get_token('refresh_token') # get a new MAC type access token |
| /** | |
| * @module describe-it | |
| * | |
| * This module defines global variables to provide unit test case runner functions compatible with mocha and jasmine. | |
| * The codebase is written for brevity and facilitate being as lightweight as possible. | |
| * | |
| * The code is intended to be included in Postman Test Sandbox. | |
| */ | |
| /** |
| require 'rubygems' | |
| require 'rack/oauth2' | |
| client = Rack::OAuth2::Client.new( | |
| :identifier => YOUR_CLIENT_ID, | |
| :secret => YOUR_CLIENT_SECRET, | |
| :redirect_uri => YOUR_REDIRECT_URI, # only required for grant_type = :code | |
| :host => 'rack-oauth2-sample.heroku.com' | |
| ) |