This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protopipe git:(master) ✗ rake ts:rebuild | |
Sphinx cannot be found on your system. You may need to configure the following | |
settings in your config/sphinx.yml file: | |
* bin_path | |
* searchd_binary_name | |
* indexer_binary_name | |
For more information, read the documentation: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protopipe git:(master) ✗ thin start | |
>> Using rack adapter | |
>> Thin web server (v1.5.0 codename Knife) | |
>> Maximum connections set to 1024 | |
>> Listening on 0.0.0.0:3000, CTRL+C to stop | |
/home/alder/.rvm/gems/ruby-1.9.3-p194@protopipe/gems/thin-1.5.0/lib/thin/backends/tcp_server.rb:16:in `connect': cannot load such file -- thin/connection (LoadError) | |
from /home/alder/.rvm/gems/ruby-1.9.3-p194@protopipe/gems/thin-1.5.0/lib/thin/backends/base.rb:55:in `block in start' | |
from /home/alder/.rvm/gems/ruby-1.9.3-p194@global/gems/eventmachine-1.0.0/lib/eventmachine.rb:187:in `call' | |
from /home/alder/.rvm/gems/ruby-1.9.3-p194@global/gems/eventmachine-1.0.0/lib/eventmachine.rb:187:in `run_machine' | |
from /home/alder/.rvm/gems/ruby-1.9.3-p194@global/gems/eventmachine-1.0.0/lib/eventmachine.rb:187:in `run' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Path to your oh-my-zsh configuration. | |
export ZSH=$HOME/.oh-my-zsh | |
# Set name of the theme to load. | |
# Look in ~/.oh-my-zsh/themes/ | |
# Optionally, if you set this to "random", it'll load a random theme each | |
# time that oh-my-zsh is loaded. | |
export ZSH_THEME="robbyrussell" | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Active Internet connections (servers and established) | |
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name | |
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 29367/ruby | |
tcp 0 0 0.0.0.0:35729 0.0.0.0:* LISTEN 3660/sublime_text | |
tcp 0 0 0.0.0.0:28017 0.0.0.0:* LISTEN 1221/mongod | |
tcp 0 0 127.0.1.1:53 0.0.0.0:* LISTEN 1465/dnsmasq | |
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 28290/sshd | |
tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 1227/cupsd | |
tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN 11088/postgres | |
tcp 0 0 127.0.0.1:9312 0.0.0.0:* LISTEN 29094/searchd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rbconfig' | |
if RbConfig::CONFIG['host_os'] =~ /linux/i | |
gem 'therubyracer', :group => [:assets] | |
gem 'libv8', '~> 3.11.8', :group => [:assets] | |
gem 'thin', :group => [:development] | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Method 1 | |
# https://github.com/ksylvest/zencodeit | |
# ENV['OMNIAUTH_PROVIDER_DATA'] used for define data through server console, that possible, but can be discarded | |
# initializers / omniauth.rb | |
config = YAML::load(File.read("#{Rails.root}/config/omniauth.yml"))[Rails.env] | |
config['twitter' ] ||= {} | |
config['facebook'] ||= {} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Login to the server via SSH: | |
~ ey ssh | |
On the server go into the right directory: | |
~ cd /data/app_name/current | |
Start the rails console with: | |
~ ey_bundler_binstubs/rails c |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class PostController < Application Controller | |
before_filter :ensure_post, only: [:show, :edit, :update, :destroy] | |
private | |
def post | |
@post ||= Post.find_by_id params[:id] | |
end | |
helper_method :post |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source 'https://rubygems.org' | |
gem 'rails', '3.2.11' | |
group :assets do | |
gem 'sass-rails', '~> 3.2.3' | |
gem 'coffee-rails', '~> 3.2.1' | |
gem 'uglifier', '~> 1.0.3' | |
gem 'compass-rails', '~> 1.0.3' | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<a href="http://localhost:3000/auth/google"><img src="/images/gg2.png" alt=""></a> | |
<div class="hero-unit"> | |
<h1>'Allo, 'Allo!</h1> | |
<button ng-click="authenticate()" class="btn btn-primary">Authenticate</button> | |
<div ng-app="directive.g+signin"> | |
<g+signin clientid="236823754682-c22gabjasrta49kj9cnjcqo0cmmfppov.apps.googleusercontent.com"></g+signin> | |
<p>^ This is a Google Plus sign-in button</p> | |
</div> |