mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-11-01 18:58:18 +00:00
update commented examples just remove $
This commit is contained in:
@@ -50,34 +50,34 @@ kubectl run NAME --image=image [--env="key=value"] [--port=port] [--replicas=rep
|
||||
|
||||
```
|
||||
# Start a single instance of nginx.
|
||||
$ kubectl run nginx --image=nginx
|
||||
kubectl run nginx --image=nginx
|
||||
|
||||
# Start a single instance of hazelcast and let the container expose port 5701 .
|
||||
$ kubectl run hazelcast --image=hazelcast --port=5701
|
||||
kubectl run hazelcast --image=hazelcast --port=5701
|
||||
|
||||
# Start a single instance of hazelcast and set environment variables "DNS_DOMAIN=cluster" and "POD_NAMESPACE=default" in the container.
|
||||
$ kubectl run hazelcast --image=hazelcast --env="DNS_DOMAIN=cluster" --env="POD_NAMESPACE=default"
|
||||
kubectl run hazelcast --image=hazelcast --env="DNS_DOMAIN=cluster" --env="POD_NAMESPACE=default"
|
||||
|
||||
# Start a replicated instance of nginx.
|
||||
$ kubectl run nginx --image=nginx --replicas=5
|
||||
kubectl run nginx --image=nginx --replicas=5
|
||||
|
||||
# Dry run. Print the corresponding API objects without creating them.
|
||||
$ kubectl run nginx --image=nginx --dry-run
|
||||
kubectl run nginx --image=nginx --dry-run
|
||||
|
||||
# Start a single instance of nginx, but overload the spec of the deployment with a partial set of values parsed from JSON.
|
||||
$ kubectl run nginx --image=nginx --overrides='{ "apiVersion": "v1", "spec": { ... } }'
|
||||
kubectl run nginx --image=nginx --overrides='{ "apiVersion": "v1", "spec": { ... } }'
|
||||
|
||||
# Start a single instance of busybox and keep it in the foreground, don't restart it if it exits.
|
||||
$ kubectl run -i --tty busybox --image=busybox --restart=Never
|
||||
kubectl run -i --tty busybox --image=busybox --restart=Never
|
||||
|
||||
# Start the nginx container using the default command, but use custom arguments (arg1 .. argN) for that command.
|
||||
$ kubectl run nginx --image=nginx -- <arg1> <arg2> ... <argN>
|
||||
kubectl run nginx --image=nginx -- <arg1> <arg2> ... <argN>
|
||||
|
||||
# Start the nginx container using a different command and custom arguments.
|
||||
$ kubectl run nginx --image=nginx --command -- <cmd> <arg1> ... <argN>
|
||||
kubectl run nginx --image=nginx --command -- <cmd> <arg1> ... <argN>
|
||||
|
||||
# Start the perl container to compute π to 2000 places and print it out.
|
||||
$ kubectl run pi --image=perl --restart=OnFailure -- perl -Mbignum=bpi -wle 'print bpi(2000)'
|
||||
kubectl run pi --image=perl --restart=OnFailure -- perl -Mbignum=bpi -wle 'print bpi(2000)'
|
||||
```
|
||||
|
||||
### Options
|
||||
@@ -147,7 +147,7 @@ $ kubectl run pi --image=perl --restart=OnFailure -- perl -Mbignum=bpi -wle 'pri
|
||||
|
||||
* [kubectl](kubectl.md) - kubectl controls the Kubernetes cluster manager
|
||||
|
||||
###### Auto generated by spf13/cobra on 14-Feb-2016
|
||||
###### Auto generated by spf13/cobra on 29-Feb-2016
|
||||
|
||||
<!-- BEGIN MUNGE: GENERATED_ANALYTICS -->
|
||||
[]()
|
||||
|
||||
Reference in New Issue
Block a user