Skip to content

Instantly share code, notes, and snippets.

View sithumonline's full-sized avatar
🏠
Working from home

Sithum Bopitiya sithumonline

🏠
Working from home
View GitHub Profile
package main
import (
"fmt"
"math/rand"
)
func main() {
var matrix = make(map[int][]string)

Shrunk Code / The Rules of Functions

how did I get this code shrunk down to

that last little bit how did that

process work my goal was to make these

functions small and I call this the

@sithumonline
sithumonline / pack-insall.sh
Last active December 17, 2020 10:27
buildpack
cd /tmp
wget https://github.com/buildpacks/pack/releases/download/<version>/pack-<version>-linux.tgz
tar -xvzf pack-<version>-linux.tgz
sudo mv pack /usr/local/bin/
pack suggest-builders
pack build image/name:tag \
--builder builder/which/you/decided \
--path path/to/app
docker push image/name:tag
apiVersion: apps/v1
kind: Deployment
metadata:
name: your-app
namespace: default
spec:
replicas: 1
selector:
matchLabels:
run: web-demo
minikube start
kubectl apply -f k8s-img.yml
kubectl get pods