Skip to content

Instantly share code, notes, and snippets.

View lrjbrual's full-sized avatar
🏠
Working from home

ryanjeff lrjbrual

🏠
Working from home
View GitHub Profile
@lrjbrual
lrjbrual / digitalocean.md
Created July 19, 2018 11:45 — forked from JamesDullaghan/digitalocean.md
Deploy rails app to digitalocean with nginx, unicorn, capistrano & postgres

Deploy Rails app to digitalocean with nginx, unicorn, capistrano & postgres

Create droplet of your liking (ubuntu 12.10 x32)

ssh to root in terminal with your server ip

ssh root@123.123.123.123

Add ssh fingerprint and enter password provided in email

@lrjbrual
lrjbrual / ruby_on_rails_deployment.md
Created July 19, 2018 11:38 — forked from zentetsukenz/ruby_on_rails_deployment.md
Deploy Ruby on Rails application with Docker Compose and Capistrano with ease

#Docker

##Files and Folders.

|
|\_ app
|...
|\_ docker
| |
@lrjbrual
lrjbrual / http-benchmark.md
Created March 6, 2018 12:01 — forked from denji/http-benchmark.md
HTTP(S) Benchmark Tools / Toolkit for testing/debugging HTTP(S) and restAPI (RESTful)
@lrjbrual
lrjbrual / postgres-cheatsheet.md
Created February 21, 2018 19:42 — forked from Kartones/postgres-cheatsheet.md
PostgreSQL command line cheatsheet

PSQL

Magic words:

psql -U postgres

Some interesting flags (to see all, use -h):

  • -E: will describe the underlaying queries of the \ commands (cool for learning!)
  • -l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)
@lrjbrual
lrjbrual / _input.blade.php
Created February 15, 2018 12:37
master branch
<?php
foreach($mkpdata as $key=>$d){
$mkpid=$d->marketplace_id;
$sid_token[$mkpid]['sid']=$d->mws_seller_id;
$sid_token[$mkpid]['token']=$d->mws_auth_token;
$remove_state[$mkpid] = '';
$verified_state[$mkpid] = '';
if(!isset($sid_token[$mkpid]['sid'])){
$sid_token[$mkpid]['sid']='';
@lrjbrual
lrjbrual / notes.md
Created May 6, 2017 19:27 — forked from sixfeetover/notes.md
MacOS Sierra upgrade for Rubyists

Upgrading to Sierra for Ruby Devs

Often when upgrading to the latest OS X MacOS you have to do a few things to account for changing to underlying libraries. Here are the post-upgrade steps I took to get back to a fully operational state. I use homebrew and rbenv to manage my environment.

1. Get your Developer Command line tools upgraded.

To do this just run

$ xcode-select --install
How to:
1. Generate in command line: rails new -T --database postgresql capstone1asyourprojectname
2. rails db:create
3. rails db:migrate
4. add to your gem file
gem 'spree', '~> 3.2.0.rc1'
gem 'spree_auth_devise', '~> 3.2.0.beta'
gem 'spree_gateway', '~> 3.2.0.beta'
5. run bundle update
6. then copy paste these in to your command line:
@lrjbrual
lrjbrual / gist:e8e6c2b5debd04dde16786d0e8124edc
Created January 25, 2017 15:45
Artisan serve got error
✝  ~/code/locksourcing/trendle   master  ls
app composer.json database public routes tests
artisan composer.lock package.json readme.md server.php webpack.mix.js
bootstrap config phpunit.xml resources storage
✝  ~/code/locksourcing/trendle   master  php artisan serve
sPHP Warning: require(/Users/ryanjeff/code/locksourcing/trendle/bootstrap/../vendor/autoload.php): failed to open stream: No such file or directory in /Users/ryanjeff/code/locksourcing/trendle/bootstrap/autoload.php on line 17
PHP Stack trace:
PHP 1. {main}() /Users/ryanjeff/code/locksourcing/trendle/artisan:0
PHP 2. require() /Users/ryanjeff/code/locksourcing/trendle/artisan:16
@lrjbrual
lrjbrual / iterm2-solarized.md
Created January 24, 2017 21:48 — forked from kevin-smets/iterm2-solarized.md
iTerm2 + Oh My Zsh + Solarized color scheme + Meslo powerline font + [Powerlevel9k] - (macOS)

Default

Default

Powerlevel9k

Powerlevel9k

@lrjbrual
lrjbrual / gist:cc507ee57d1ae5ae1c21371d1e992940
Created December 28, 2016 16:55 — forked from johnantoni/gist:07df65898456ace4307d5bb6cbdc7f51
Nginx, PHP-FPM, MySQL and phpMyAdmin on OS X

This is my take on how to get up and running with NGINX, PHP-FPM, MySQL and phpMyAdmin on OSX Yosemite.

This article is adapted from the original by Jonas Friedmann. Who I just discovered is from Würzburg in Germany. A stonesthrow from where I was born ;)

Xcode

Make sure you have the latest version of XCode installed. Available from the Mac App Store.

Install the Xcode Command Line Tools:

xcode-select --install