Skip to content

Instantly share code, notes, and snippets.

View relaxdiego's full-sized avatar
🤓

Mark Maglana relaxdiego

🤓
  • The Linux Foundation
  • Earth, Solar System, Milky Way, Laniakea
View GitHub Profile
log --graph --pretty=oneline --abbrev-commit --decorate --color --all

git-flow completion requires git-completion to work. How exactly you go about installing git-completion varies wildly from system to system, so it's hard to give exact installation instructions.

OS X

By far the easiest way to install both Git and git-completion is via Homebrew, so you should pick that one.

Homebrew

  1. Install homebrew
@relaxdiego
relaxdiego / install-tmux
Last active December 7, 2021 16:09 — forked from rothgar/install-tmux
Install tmux 2.2 on CentOS 7.1
# install deps
yum install gcc kernel-devel make ncurses-devel
# DOWNLOAD SOURCES FOR LIBEVENT AND MAKE AND INSTALL
wget https://github.com/downloads/libevent/libevent/libevent-2.0.21-stable.tar.gz
tar -xvzf libevent-2.0.21-stable.tar.gz
cd libevent-2.0.21-stable
./configure --prefix=/usr/local
make
sudo make install
@relaxdiego
relaxdiego / in_main.py
Last active January 7, 2019 08:55
Initialize in main() vs outside main()
#!/usr/bin/python
from ansible.module_utils.basic import AnsibleModule
def main():
mod = AnsibleModule(
argument_spec=dict(
url=dict(required=True),
dest=dict(required=False, default="/tmp/firstmod")
)
@relaxdiego
relaxdiego / README.md
Created March 23, 2017 17:58 — forked from dnozay/_Jenkins+Script+Console.md
jenkins groovy scripts collection.
@relaxdiego
relaxdiego / golang-tls.md
Last active January 8, 2020 06:46 — forked from denji/golang-tls.md
OpenSSL TLS

Moved to git repository: https://github.com/denji/golang-tls

Generate private key (.key)
# Key considerations for algorithm "RSA" ≥ 2048-bit
openssl genrsa -out server.key 2048

# Key considerations for algorithm "ECDSA" ≥ secp384r1
# List ECDSA the supported curves (openssl ecparam -list_curves)
@relaxdiego
relaxdiego / readme.adoc
Created May 18, 2017 17:41 — forked from arun-gupta/readme.adoc
Kubernetes Cluster on AWS
  1. kops: https://github.com/kubernetes/kops

    1. Getting Started Guide: https://github.com/kubernetes/kops/blob/master/docs/aws.md

    2. Installing Kubernetes on AWS with kops: https://kubernetes.io/docs/getting-started-guides/kops/

    3. Mulit-master Kubernetes Cluster on AWS with kops: http://blog.arungupta.me/multimaster-kubernetes-cluster-amazon-kops/

    4. Booting Kubernetes on Amazon Elastic Compute with kops: https://deis.com/docs/workflow/quickstart/provider/aws/boot/

    5. Setting up an HA Kubernetes Cluster in AWS with private topology with kops 1.5.1: https://www.nivenly.com/kops-1-5-1/

    6. Kubernetes on AWS: https://daemonza.github.io/2017/01/15/kubernetes-on-aws/

    7. Your 2nd day with Kubernetes on AWS: https://www.nivenly.com/2nd-hour/

  2. Tectonic (Terraform): http://github.com/coreos/tectonic-installer

@relaxdiego
relaxdiego / upload-github-release-asset.sh
Created July 4, 2017 18:22 — forked from stefanbuck/upload-github-release-asset.sh
Script to upload a release asset using the GitHub API v3.
#!/usr/bin/env bash
#
# Author: Stefan Buck
# https://gist.github.com/stefanbuck/ce788fee19ab6eb0b4447a85fc99f447
#
#
# This script accepts the following parameters:
#
# * owner
# * repo
kind: List
apiVersion: v1
items:
- kind: Namespace
apiVersion: v1
metadata:
name: guestbook
- kind: Deployment
#!/bin/bash
set -e
arch=${1:-amd64}
repo=${2:-"http://ftp.us.debian.org/debian/dists/stable/main"}
url="${repo}/Contents-${arch}.gz"
gz_path="$HOME/.deb_content_files/$(sed -r 's|https?://||g' <<< $url)"
txt_path=${gz_path/%.gz/}