Skip to content

Instantly share code, notes, and snippets.

John Morales JohnMorales

  • Northern Virginia
Block or report user

Report or block JohnMorales

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
@pepa65
pepa65 / .gitignore
Last active Aug 25, 2017
Improving update-grub (grub-mkconfig), only include versions that are included in the root partition's /lib/modules
View .gitignore
10_linux
10_linux.new
10_linux.old
30_os-prober
30_os-prober.new
30_os-prober.old
@tony-gutierrez
tony-gutierrez / AWS_Single_LetsEncrypt.yaml
Last active Oct 17, 2019
AWS Elastic Beanstalk .ebextensions config for single instance free SSL using letsencrypt certbot and nginx. http://bluefletch.com/blog/domain-agnostic-letsencrypt-ssl-config-for-elastic-beanstalk-single-instances/
View AWS_Single_LetsEncrypt.yaml
# Dont forget to set the env variable "certdomain", and either fill in your email below or use an env variable for that too.
# Also note that this config is using the LetsEncrypt staging server, remove the flag when ready!
Resources:
sslSecurityGroupIngress:
Type: AWS::EC2::SecurityGroupIngress
Properties:
GroupId: {"Fn::GetAtt" : ["AWSEBSecurityGroup", "GroupId"]}
IpProtocol: tcp
ToPort: 443
View gist:e95cdc230d1ac5b824b3
# install build dependencies
sudo yum install -y git-core zlib zlib-devel gcc-c++ patch readline readline-devel libyaml-devel libffi-devel openssl-devel make bzip2 autoconf automake libtool bison curl sqlite-devel
# clone and install rbenv environment
cd ~
git clone git://github.com/sstephenson/rbenv.git .rbenv
git clone git://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
echo 'export PATH="$HOME/.rbenv/bin:$HOME/.rbenv/plugins/ruby-build/bin:$PATH"' >> ~/.bash_profile
echo 'eval "$(rbenv init -)"' >> ~/.bash_profile
@choppsv1
choppsv1 / tmux-24.diff
Last active Dec 21, 2018
True color (24-bit) terminal support for tmux-1.9a and tmux-2.0
View tmux-24.diff
This diff is a modified version of a diff written by Arnis Lapsa.
[ The original can be found here: https://gist.github.com/ArnisL/6156593 ]
This diff adds support to tmux for 24-bit color CSI SRG sequences. This
allows terminal based programs that take advantage of it (e.g., vim or
emacs with https://gist.github.com/choppsv1/73d51cedd3e8ec72e1c1 patch)
to display 16 million colors while running in tmux.
The primary change I made was to support ":" as a delimeter as well
@ismell
ismell / README.md
Last active Sep 10, 2016
Docker Ubuntu upstart scripts
View README.md

Production Ready Process Monitoring

  1. Install docker-manger.conf and docker-instance.conf in /etc/init

  2. Create a containers file in /etc/docker/ with the following format

     name: image cmd
    

    The name must be unique.

  3. sudo service docker-manager start

@rgreenjr
rgreenjr / postgres_queries_and_commands.sql
Last active Oct 17, 2019
Useful PostgreSQL Queries and Commands
View postgres_queries_and_commands.sql
-- show running queries (pre 9.2)
SELECT procpid, age(clock_timestamp(), query_start), usename, current_query
FROM pg_stat_activity
WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%'
ORDER BY query_start desc;
-- show running queries (9.2)
SELECT pid, age(clock_timestamp(), query_start), usename, query
FROM pg_stat_activity
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%'
@jessieay
jessieay / ActiveRecord Cheat Sheet v1
Created Jul 17, 2012
Active Record cheat sheet with examples of queries I've needed most so far
View ActiveRecord Cheat Sheet v1
ActiveRecord cheat sheet / EXAMPLES
INSTALL
=======
$ gem install activerecord
in GEMFILE: gem ‘activerecord’
REQUIRE
=======
require ‘active_record’
@shripadk
shripadk / gist:552554
Created Aug 27, 2010
Setting up Heroku Hostname SSL with GoDaddy SSL Cert
View gist:552554
How to setup Heroku Hostname SSL with GoDaddy SSL Certificate and Zerigo DNS
Heroku recently added an exciting new 'Hostname SSL' option. This option offers the broad compatibility of IP-based SSL, but at 1/5 the price ($20 / month at the time of this writing).
The following tutorial explains how to use Heroku's new 'Hostname SSL' option on your Heroku project. Before we begin, let's list what we're using here:
* Heroku Hostname SSL
* GoDaddy Standard SSL Certificate
* Zerigo DNS
You can’t perform that action at this time.