Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

vignesh vigneshragupathy

🎯
Focusing
View GitHub Profile
View hello.py
import sys
print "hello world"
View stress.test.yaml
spec:
containers:
- image: vish/stress
imagePullPolicy: Always
name: stress-test
resources:
limits:
cpu: "1"
memory: "4Gi"
requests:
@vigneshragupathy
vigneshragupathy / nginx_redirect.conf
Last active Aug 23, 2018
Sample nginx redirection
View nginx_redirect.conf
server {
listen 80;
server_name www.XXXX.com;
return 301 https://www.YYYY.com$request_uri;
}
@vigneshragupathy
vigneshragupathy / limit_range.yaml
Last active Aug 26, 2018
blog kubernetes limit setting for namespace
View limit_range.yaml
apiVersion: v1
kind: LimitRange
metadata:
name: low-usage-limit-range
spec:
limits:
- default:
cpu: 1
memory: 500Mi
defaultRequest:
View stress-test-limited-58b76c667f-ssthq.yaml
apiVersion: v1
kind: Pod
metadata:
annotations:
kubernetes.io/limit-ranger: 'LimitRanger plugin set: cpu, memory request for container
stress-test-limited; cpu, memory limit for container stress-test-limited'
creationTimestamp: 2018-08-26T14:23:37Z
generateName: stress-test-limited-58b76c667f-
labels:
pod-template-hash: "1463272239"
@vigneshragupathy
vigneshragupathy / replicate_set.yaml
Created Sep 29, 2018
yaml file to create a simple replica sets
View replicate_set.yaml
apiVersion: extensions/v1beta1
kind: ReplicaSet
metadata:
name: replicate-set-vikki
spec:
replicas: 2
template:
metadata:
labels:
system: ReplicaOne
@vigneshragupathy
vigneshragupathy / kubernetes-strace-eo.st
Last active Sep 29, 2018
strace output for "strace kubectl get endpoints"
View kubernetes-strace-eo.st
openat(AT_FDCWD, "/home/vikki/.kube/cache/discovery/160.0.0.1_6443/autoscaling/v2beta1/serverresources.json", O_RDONLY|O_CLOEXEC) = 5
openat(AT_FDCWD, "/home/vikki/.kube/cache/discovery/160.0.0.1_6443/batch/v1/serverresources.json.987875345", O_RDWR|O_CREAT|O_EXCL|O_CLOEXEC, 0600) = -1 EACCES (Permission denied)
openat(AT_FDCWD, "/home/vikki/.kube/cache/discovery/160.0.0.1_6443/batch/v1beta1/serverresources.json", O_RDONLY|O_CLOEXEC) = 5
openat(AT_FDCWD, "/home/vikki/.kube/cache/discovery/160.0.0.1_6443/policy/v1beta1/serverresources.json.834786845", O_RDWR|O_CREAT|O_EXCL|O_CLOEXEC, 0600) = -1 EACCES (Permission denied)
openat(AT_FDCWD, "/home/vikki/.kube/cache/discovery/160.0.0.1_6443/rbac.authorization.k8s.io/v1/serverresources.json", O_RDONLY|O_CLOEXEC) = 5
openat(AT_FDCWD, "/home/vikki/.kube/cache/discovery/160.0.0.1_6443/admissionregistration.k8s.io/v1beta1/serverresources.json.571841542", O_RDWR|O_CREAT|O_EXCL|O_CLOEXEC, 0600) = -1 EACCES (Permission denied)
openat(AT_FDCWD, "/home/vikki/.kube/cache/dis
View replicate-set-vikki-2nkhr.yaml
# Please edit the object below. Lines beginning with a '#' will be ignored,
# and an empty file will abort the edit. If an error occurs while saving this file will be
# reopened with the relevant failures.
#
apiVersion: v1
kind: Pod
metadata:
creationTimestamp: 2018-09-29T07:38:40Z
generateName: replicate-set-vikki-
labels:
View daemon_set.yaml
apiVersion: extensions/v1beta1
kind: DaemonSet
metadata:
name: daemon-set-vikki
spec:
template:
metadata:
labels:
system: DaemonSetOne
spec:
View daemon-set-vikki-roll-update.yaml
# Please edit the object below. Lines beginning with a '#' will be ignored,
# and an empty file will abort the edit. If an error occurs while saving this file will be
# reopened with the relevant failures.
#
apiVersion: extensions/v1beta1
kind: DaemonSet
metadata:
creationTimestamp: 2018-09-29T13:04:57Z
generation: 2
labels: