This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Kubernetes | |
// dry run a pod and dump o/p def in yaml file | |
kubectl run redis --image=redis --dry-run=client -o yaml > pod-definition.yaml | |
// dump run pod def in yaml file | |
kubectl get pod <pod-name> -o yaml > pod-definition.yaml | |
// edit current pod | |
kubectl edit pod <pod-name> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Docker cheat book | |
// Download image and run the docker container | |
> docker run <image-name> <commands-to-be-run-inside-image> | |
// run bash inside centos docker image with attached STDIN and TTY | |
> docker run -it centos bash | |
// run docker container with docker image and given version |