This is what I can remember:
curl -L j.mp/bash-completion-docker | sh
or if you dont like curl-pipe, do it by hand:
ln -s /Applications/Docker.app/Contents/Resources/etc/docker.bash-completion /usr/local/etc/bash_completion.d/docker
{ | |
"orders":[ | |
{ | |
"id": 1, | |
"user": "lalyos", | |
"food": "pacal" | |
}, | |
{ | |
"id": 2, | |
"user": "geza", |
Sometimes a very simple prompt is useful - like creating documentation, or github issues. In those cases its still important to be able to tell the k8s context/ns
white [ctx/ns]
PS1='[$(kubectl config view --minify -o jsonpath="{.contexts[0].name}:{.contexts[0].context.namespace}")]$ '
orange [ns]
Fake/Quick rest api prototype by combinig:
docker run -d \
--name json-server \
-p 3000:3000 \
lalyos/json-server https://gist.githubusercontent.com/lalyos/2be21105e3607b4981c85a542cedc7fc/raw/issues.json
kubectl apply -f https://gist.githubusercontent.com/lalyos/1f70f30127ae88be6deaa3f12b377f69/raw/secret-app.yaml
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: bad-app | |
spec: | |
replicas: 0 | |
selector: | |
matchLabels: | |
app: bad | |
template: |
apiVersion: v1 | |
kind: Service | |
metadata: | |
creationTimestamp: null | |
labels: | |
app: lunch | |
name: lunch | |
spec: | |
type: NodePort | |
ports: |
apiVersion: extensions/v1beta1 | |
kind: Ingress | |
metadata: | |
name: web | |
spec: | |
rules: | |
- host: web.$NS.ing.k8z.eu | |
http: | |
paths: | |
- backend: |