Skip to content

Instantly share code, notes, and snippets.

View mateothegreat's full-sized avatar
🤘
it ain't easy.

Matthew Davis mateothegreat

🤘
it ain't easy.
View GitHub Profile
@mateothegreat
mateothegreat / github.api.gists.create.example
Created July 3, 2016 16:43
Demo using bash and cURL to create a gist with several files.
Book: <..>
Title: Show by example
Author: Matthew Davis <matthew@appsoa.io>
@mateothegreat
mateothegreat / Snippets for Docker.md
Last active July 15, 2016 17:18
Dockerfile & docker-compose.yml Snippets

Dockerfile & docker-compose.yml Snippets

Define your app’s environment with a Dockerfile so it can be reproduced anywhere.

####Build, Ship, Run. An open platform for distributed applications for developers and sysadmins.

Define the services that make up your app in docker-compose.yml so they can be run together in an isolated environment. Lastly, run docker-compose up and Compose will start and run your entire app. -https://docs.docker.com/compose

@mateothegreat
mateothegreat / c9.sh
Created January 28, 2017 08:06
Prepare CentOS for Cloud9 ("c9") remote ssh workspace
# Prepare dependencies
sudo yum -y groupinstall "Development Tools" && \
sudo yum -y install ncurses-devel \
glibc-static &&
# Install Node Version Manager ("nvm")
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.0/install.sh | bash &&
# Install node.js
nvm install v6.9.4 &&
@mateothegreat
mateothegreat / aws
Created March 4, 2017 03:00 — forked from QaDeS/aws
Grok patterns to parse AWS access logs
IAMUSERID %{NUMBER:iam_user_id}
IAMUSERNAME [a-zA-Z0-9._-]+
IAMUSER arn:aws:iam::%{IAMUSERID}:user/%{IAMUSERNAME:iam_user_name}
S3TYPE (?:OBJECT)
S3OP [a-zA-z]+
S3SOAPOPERATION (?:SOAP\.%{S3OP})
S3RESTOPERATION (?:REST\.%{S3OP}\.%{S3TYPE})
S3WEBSITEOPERATION (?:WEBSITE\.%{S3OP}\.%{S3TYPE})
S3OPERATION (?:%{S3SOAPOPERATION}|%{S3RESTOPERATION}|%{S3WEBSITEOPERATION})
@mateothegreat
mateothegreat / .block
Created May 5, 2017 06:56 — forked from mbostock/.block
Radial Tidy Tree
license: gpl-3.0
border: no
height: 1060

install kubernetes 1.6 on centos 7.3

Install kubelet, kubeadm, docker, kubectl and kubernetes-cni

1. Install Yum Repo

cat <<EOF > /etc/yum.repos.d/kubernetes.repo
[kubernetes]
name=Kubernetes
baseurl=http://yum.kubernetes.io/repos/kubernetes-el7-x86_64
@mateothegreat
mateothegreat / get_uninstallable_programs.ps1
Created June 15, 2017 13:41
Get list of programs that can be uninstalled automatically.
PS C:\Windows\system32> New-PSDrive -Name Uninstall -PSProvider Registry -Root HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
PS C:\Windows\system32> dir Uninstall: | Get-ItemProperty -Name DisplayName, InstallDate, Publisher, InstallLocation, UninstallString, ModifyPath, EstimatedSize -ErrorAction SilentlyContinue | Sort-Object -Property DisplayName -ErrorAction SilentlyContinue
@mateothegreat
mateothegreat / README-Template.md
Created August 15, 2017 20:42 — forked from PurpleBooth/README-Template.md
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@mateothegreat
mateothegreat / aliases.sh
Created August 31, 2017 19:09 — forked from JulienBreux/aliases.sh
Kubernetes term aliases
# Used to run minikube shortly
alias mk="minikube"
# Used to run kubectl shortly
alias k="kubectl"
# Used to get ...
alias kg="kubectl get"
# Used to get all pods
@mateothegreat
mateothegreat / docker_remove_images_containers.sh
Created October 17, 2017 09:24
Remove Docker Images & Containers
#!/bin/bash
# Delete all containers
docker rm -f $(docker ps -a -q)
# Delete all images
docker rmi -f $(docker images -q)