Skip to content

Instantly share code, notes, and snippets.

View ProProgrammer's full-sized avatar

Deep Sukhwani ProProgrammer

View GitHub Profile
@ProProgrammer
ProProgrammer / new-contributor-workshop-part1.txt
Last active October 7, 2018 13:51
Notes from 2018 Kubernetes Contributor Summit EU New Contributor Workshop Part 1 - https://www.youtube.com/watch?v=obyAKf39H38
Watch - 2018 Kubernetes Contributor Summit EU New Contributor Workshop Part 1 - https://www.youtube.com/watch?v=obyAKf39H38
CLA Signing: https://git.k8s.io/community/CLA.md
Actual URL: https://github.com/kubernetes/community/blob/master/CLA.md
SIG == Special Interest Group
Project humans organized in SIGs
Docs and Website
Frontend development
SIGs:
@ProProgrammer
ProProgrammer / useful_gcloud_kubectl.sh
Last active April 10, 2019 07:34
Some Google Cloud (gcloud) and Kubernetes (kubectl) commands to mess around
# Delete a node-pool
gcloud container node-pools delete pool-n1-standard-4-non-preemptible --region us-central1 --cluster cluster-2 --quiet
# Create a node-pool
gcloud container node-pools create pool-n1-standard-4-non-preemptible --cluster cluster-2 --disk-size 30GB --disk-type pd-ssd --enable-autorepair --enable-autoupgrade --machine-type n1-standard-4 --num-nodes 1 --enable-autoscaling --min-nodes 0 --max-nodes 5 --region us-central1
# Drain a node and delete GCE Instance:
INSTANCE=gke-cluster-2-pool-n1-standard-4-50c3bfa2-fwxn; kubectl drain --delete-local-data --ignore-daemonsets --grace-period=10 $INSTANCE; kubectl delete node $INSTANCE; gcloud compute instances delete $INSTANCE --quiet --zone us-central1-a
OR
for node in $(kubectl get nodes -l cloud.google.com/gke-nodepool=pool-n1-standard-4 -o name); do kubectl drain --ignore-daemonsets --delete-local-data --grace-period=10 ${node}; kubectl delete ${node}; done
@ProProgrammer
ProProgrammer / understanding-pointers.go
Last active June 12, 2019 17:07
Trying to understand pointers in Golang while going through Golang Tour
package main
import "fmt"
func main() {
a := 200
b := &a // Point to memory address of variable a
fmt.Println("Initial value of variable a:", a)
fmt.Println("b := &a, hence value of b:", b)
fmt.Println("Value of *b:", *b) // You can access the value in memory location to whicht he value points using asterisk before the variable name
@ProProgrammer
ProProgrammer / awesome-cli.md
Last active February 22, 2020 03:01
Awesome Command Line Tools by Amjith Ramanujam

Third in Top 10 Must-Watch PyCon Talks by RealPython

Youtube | Slides | Date: Feb 22, 2020

Things to be super aware of

  • Discoverability - Make your features more obvious/forthcoming, don't hide them behind something (e.g. a particular key stroke combination in case of command line tools)
  • Be User focussed - Whatever you are building an application/feature, user comes first, make it most intutitive and absolutely powerful for the user, implementation should always come next
  • Configurability - Root of all evil! (Inspired by design decisions of Fish Shell) Adding config options means program too stupid to figure out what's best for the user. Configurations should be for subjective options only (e.g. color schemes based on indiv preferences)