Skip to content

Instantly share code, notes, and snippets.

View moesy's full-sized avatar
🌴

Moe Sy moesy

🌴
View GitHub Profile
#!/bin/bash
# Function to retrieve and validate project ID
#
# Args:
# $1: The potential project ID to validate.
#
# Returns:
# A validated project ID on success, exits with an error message on failure.
get_project_id() {
@moesy
moesy / disable-nuveau.sh
Last active August 21, 2018 18:01
Ubuntu 18.x Nvidia Server
echo "blacklist nouveau
options nouveau modeset=0" >> /etc/modprobe.d/blacklist-nouveau.conf
update-initramfs -u
reboot
@moesy
moesy / juju.sh
Last active January 11, 2018 02:59
sudo apt-add-repository ppa:juju/stable
sudo apt-get update
sudo apt-get install juju-local
ju generate-config
juju switch local
sudo apt-get install libxml2-dev libxslt1-dev
sudo yum install libxml2-devel libxslt-devel
sudo yum install gcc python-setuptools python-devel postgresql-devel
sudo yum install libevent-devel
sudo yum -y install libffi-devel openssl-devel
sudo pip install psycopg2
sudo pip install flask_bcrypt
@moesy
moesy / jruby-amazon-linux.bash
Created December 31, 2016 22:39 — forked from kainam00/jruby-amazon-linux.bash
Install jruby on Amazon Linux
#!/bin/bash
# Install prerequisites
yum install -y gcc openssl-devel libyaml-devel libffi-devel readline-devel zlib-devel gdbm-devel ncurses-devel ruby-devel gcc-c++ jq git
# Import key
curl -sSL https://rvm.io/mpapis.asc | gpg2 --import -
# Install RVM
curl -sSL https://get.rvm.io | bash -s stable --ruby
@moesy
moesy / US_zipcode_to_geopoint.yaml
Created December 16, 2016 02:44 — forked from snandam/US_zipcode_to_geopoint.yaml
Data to use to translate zipcode or postal code to geopoint : logstash transform filter
This file has been truncated, but you can view the full file.
"70175": "30.06, -89.93"
"11542": "40.86, -73.63"
"11547": "40.82, -73.63"
"11545": "40.84, -73.61"
"11548": "40.81, -73.62"
"11549": "40.7, -73.61"
"19399": "40.05, -75.41"
"19398": "40.05, -75.41"
"19397": "40.05, -75.41"
"19395": "39.93, -75.55"
sudo pip install speedtest-cli
# Test w/ https
speedtest-cli --secure
@moesy
moesy / ._wild-cherry.zsh-theme
Last active August 22, 2016 00:45
Provision scripts for workstations