Skip to content

Instantly share code, notes, and snippets.

Luis pathcl

Block or report user

Report or block pathcl

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
View main.go
package main
import (
"crypto/tls"
"crypto/x509"
"encoding/json"
"encoding/pem"
"flag"
"io/ioutil"
"log"
@pathcl
pathcl / ingress.go
Created Oct 9, 2019
Get ingress using tls from k8s
View ingress.go
// Problem
// - we simply want to check ssl certs on ingress on kubernetes
package main
import (
"flag"
"fmt"
"os"
"path/filepath"
View .vimrc
" vim-bootstrap b0a75e4
"*****************************************************************************
"" Vim-PLug core
"*****************************************************************************
if has('vim_starting')
set nocompatible " Be iMproved
endif
let vimplug_exists=expand('~/.vim/autoload/plug.vim')
@pathcl
pathcl / kubeadm.yaml
Last active Sep 16, 2019
kind configuration for multi master
View kubeadm.yaml
# this config file contains all config fields with comments
kind: Cluster
apiVersion: kind.sigs.k8s.io/v1alpha3
# patch the generated kubeadm config with some extra settings
kubeadmConfigPatches:
- |
apiVersion: kubeadm.k8s.io/v1beta2
kind: ClusterConfiguration
metadata:
name: config
@pathcl
pathcl / test.py
Last active Aug 14, 2019
test.py
View test.py
import os
def main():
print("Os: {}".format(os.uname().version))
print("Hostname: {}".format(os.uname().nodename))
if __name__ == "__main__":
main()
@pathcl
pathcl / dns.tf
Last active Jul 26, 2019
Dns && terraform
View dns.tf
// Configure the DNS Provider
// dnssec-keygen -r /dev/urandom -a HMAC-MD5 -b 256 -n HOST domain.tld.
provider "dns" {
update {
server = "192.168.0.1"
key_name = "domain.tld."
key_algorithm = "hmac-md5"
key_secret = "yoursecrethere"
}
}
@pathcl
pathcl / npm-using-https-for-git.sh
Created May 9, 2019 — forked from taoyuan/npm-using-https-for-git.sh
Force git to use https:// instead of git://
View npm-using-https-for-git.sh
git config --global url."https://github.com/".insteadOf git@github.com:
git config --global url."https://".insteadOf git://
@pathcl
pathcl / tmux.md
Created May 8, 2019 — forked from andreyvit/tmux.md
tmux cheatsheet
View tmux.md

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

# remap prefix to Control + a
View helloworld.yaml
---
kind: Deployment
apiVersion: extensions/v1beta1
metadata:
name: whoami
labels:
app: whoami
spec:
replicas: 2
selector:
View .vimrc
" vim-bootstrap b0a75e4
"*****************************************************************************
"" Vim-PLug core
"*****************************************************************************
if has('vim_starting')
set nocompatible " Be iMproved
endif
let vimplug_exists=expand('~/.vim/autoload/plug.vim')
You can’t perform that action at this time.