Skip to content

Instantly share code, notes, and snippets.

View jamesdube's full-sized avatar
🛰️
To the moon

James Dube jamesdube

🛰️
To the moon
View GitHub Profile
@jamesdube
jamesdube / 0_reuse_code.js
Created October 27, 2016 15:58
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@jamesdube
jamesdube / Linux Static IP
Created March 27, 2017 10:50 — forked from fernandoaleman/Linux Static IP
How To Configure Static IP On CentOS 6
## Configure eth0
#
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
NM_CONTROLLED="yes"
ONBOOT=yes
HWADDR=A4:BA:DB:37:F1:04
TYPE=Ethernet
BOOTPROTO=static
@jamesdube
jamesdube / gist:155345a79b9fef0d972999862d8f3791
Created June 6, 2018 18:10 — forked from lttlrck/gist:9628955
rename git branch locally and remotely
git branch -m old_branch new_branch # Rename branch locally
git push origin :old_branch # Delete the old branch
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote
@jamesdube
jamesdube / coreos-virtualbox.md
Created June 25, 2018 10:45 — forked from noonat/coreos-virtualbox.md
Installing CoreOS on VirtualBox
  • Download and install VirtualBox.
  • Download the CoreOS ISO
  • Create a new VM in VirtualBox
    • For the OS, Other Linux, 64-bit should be fine
    • Give the VM 1gb of memory, like your physical hardware has.
    • Create a disk of whatever size you want. I made a VMDK file that could expand dynamically up to 8gb.
  • Mount the ISO in the VM
    • Right click on the VM and click settings
  • Go to the storage tab
@jamesdube
jamesdube / README.md
Created August 5, 2018 16:25 — forked from manics/README.md
Setup a single node Kubernetes cluster for development using kubeadm

kubeadm cloudinit

Setup a single node Kubernetes cluster for development using kubeadm: https://kubernetes.io/docs/setup/independent/install-kubeadm/

Create a CentOS 7 or Ubuntu Xenial (16.04) machine, and run kubeadm.sh as root.

You can pass this script as user-data to cloud-init so that it will be automatically run. For example, on openstack:

openstack server create NAME --flavor FLAVOR --key-name KEY --image 'Ubuntu Xenial' --network NET --security-group SECGROUP --user-data kubeadm.sh

@jamesdube
jamesdube / git nah
Created September 26, 2018 12:38 — forked from benjcal/git nah
alias nah="git reset --hard && git clean -df"
@jamesdube
jamesdube / .bash_aliases
Created September 26, 2018 12:38 — forked from neoighodaro/.bash_aliases
Bash Aliases
# PHP
alias artisan="php artisan"
alias art="php artisan"
# Git
alias gc="git commit"
alias ga="git add"
alias gr="git rm"
alias gp="git push"
alias gs="git status"
@jamesdube
jamesdube / example .travis.yml
Created October 9, 2018 10:26 — forked from jay-johnson/example .travis.yml
example .travis.yml
sudo: required
language: ruby
services:
- docker
before_install:
- echo "Testing Docker Hub credentials"
- docker login -e=$DOCKER_EMAIL -u=$DOCKER_USERNAME -p=$DOCKER_PASSWORD
http://cronus.allowed.org works for me, 2018.1.6
@jamesdube
jamesdube / output
Created February 8, 2019 13:15 — forked from halberom/output
ansible - example of dict with array of arrays
PLAY [foo] ********************************************************************
GATHERING FACTS ***************************************************************
ok: [localhost]
TASK: [role1 | debug var=redis] ***********************************************
ok: [localhost] => {
"redis": {
"database_save_times": [
[