Skip to content

Instantly share code, notes, and snippets.

Avatar

Kevin GEORGES d33d33

View GitHub Profile
View service.yml
kind: Service
apiVersion: v1
metadata:
name: my-lb
spec:
selector:
app: my-app
ports:
- name: http
protocol: TCP
View netrig.yaml
apiVersion: v1
kind: Namespace
metadata:
name: netrig
---
apiVersion: v1
kind: ServiceAccount
metadata:
@d33d33
d33d33 / README.md
Last active Mar 17, 2021
OVH ingress LB
View README.md

OVH ingress LB

This gist describe how to deploy a K8S LB at OVH and preserve source IP

Howto

1. Install the NGINX Ingress Controller

kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/master/deploy/static/mandatory.yaml
View ingress.go
// Time
rnow := false
now := time.Now().UnixNano() / 1000
// Get NOW header
nowh := req.Header.Get("X-Warp10-Now")
if nowh == "*" {
rnow = true
} else if strings.HasPrefix(nowh, "+") || strings.HasPrefix(nowh, "-") {
delta, err := strconv.ParseInt(nowh, 10, 64)
View CLA
Developer Certificate of Origin Version 1.1
Copyright (C) 2004, 2006 The Linux Foundation and its contributors. 660 York Street, Suite 102, San Francisco, CA 94110 USA
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
Developer's Certificate of Origin 1.1
By making a contribution to this project, I certify that:
View CLA-Beamium
Developer Certificate of Origin Version 1.1
Copyright (C) 2004, 2006 The Linux Foundation and its contributors. 660 York Street, Suite 102, San Francisco, CA 94110 USA
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
Developer's Certificate of Origin 1.1
By making a contribution to this project, I certify that:
View CLA-Metronome
Developer Certificate of Origin Version 1.1
Copyright (C) 2004, 2006 The Linux Foundation and its contributors. 660 York Street, Suite 102, San Francisco, CA 94110 USA
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
Developer's Certificate of Origin 1.1
By making a contribution to this project, I certify that:
View keybase.md

Keybase proof

I hereby claim:

  • I am d33d33 on github.
  • I am d33d33 (https://keybase.io/d33d33) on keybase.
  • I have a public key ASDP2M5k6JOT7ogY0UCVLRIBF7HuPQdTI6fNx4C40RvyAAo

To claim this, I am signing this object:

@d33d33
d33d33 / html
Created Dec 8, 2013
AngularJS directive for bootstrap-switch
View html
<div class="switch" bootstrap-switch state="user.isAdmin">
<input type="checkbox" />
</div>