File tree Expand file tree Collapse file tree 4 files changed +17
-17
lines changed Expand file tree Collapse file tree 4 files changed +17
-17
lines changed Original file line number Diff line number Diff line change 13
13
14
14
- Create a deployment:
15
15
16
- ` kubectl create deployment {{deployment_name}} --image={{image}} `
16
+ ` kubectl create {{[deploy| deployment]}} {{deployment_name}} --image={{image}} `
17
17
18
18
- Create a deployment with replicas:
19
19
20
- ` kubectl create deployment {{deployment_name}} --image={{image}} --replicas={{number_of_replicas}} `
20
+ ` kubectl create {{[deploy| deployment]}} {{deployment_name}} --image={{image}} --replicas={{number_of_replicas}} `
21
21
22
22
- Create a service:
23
23
24
- ` kubectl create service {{service_type}} {{service_name}} --tcp={{port}}:{{target_port}} `
24
+ ` kubectl create {{[svc| service]}} {{service_type}} {{service_name}} --tcp={{port}}:{{target_port}} `
25
25
26
26
- Create a namespace:
27
27
28
- ` kubectl create namespace {{namespace_name}} `
28
+ ` kubectl create {{[ns| namespace]}} {{namespace_name}} `
Original file line number Diff line number Diff line change 5
5
6
6
- Delete a specific pod:
7
7
8
- ` kubectl delete pod {{pod_name}} `
8
+ ` kubectl delete {{[po| pod]}} {{pod_name}} `
9
9
10
10
- Delete a specific deployment:
11
11
12
- ` kubectl delete deployment {{deployment_name}} `
12
+ ` kubectl delete {{[deploy| deployment]}} {{deployment_name}} `
13
13
14
14
- Delete a specific node:
15
15
16
- ` kubectl delete node {{node_name}} `
16
+ ` kubectl delete {{[no| node]}} {{node_name}} `
17
17
18
18
- Delete all pods in a specified namespace:
19
19
20
- ` kubectl delete pods --all -- namespace {{namespace}} `
20
+ ` kubectl delete {{[po| pods]}} --all {{[-n|-- namespace]}} {{namespace}} `
21
21
22
22
- Delete all deployments and services in a specified namespace:
23
23
24
- ` kubectl delete deployments,services --all -- namespace {{namespace}} `
24
+ ` kubectl delete {{[deploy|deployment]}},{{[svcľservices]}} --all {{[-n|-- namespace]}} {{namespace}} `
25
25
26
26
- Delete all nodes:
27
27
28
- ` kubectl delete nodes --all `
28
+ ` kubectl delete {{[no| nodes]}} --all `
29
29
30
30
- Delete resources defined in a YAML manifest:
31
31
Original file line number Diff line number Diff line change 5
5
6
6
- Show details of pods in a namespace:
7
7
8
- ` kubectl describe pods {{[-n|--namespace]}} {{namespace}} `
8
+ ` kubectl describe {{[po| pods]}} {{[-n|--namespace]}} {{namespace}} `
9
9
10
10
- Show details of nodes in a namespace:
11
11
12
- ` kubectl describe nodes {{[-n|--namespace]}} {{namespace}} `
12
+ ` kubectl describe {{[no| nodes]}} {{[-n|--namespace]}} {{namespace}} `
13
13
14
14
- Show the details of a specific pod in a namespace:
15
15
16
- ` kubectl describe pods {{pod_name}} {{[-n|--namespace]}} {{namespace}} `
16
+ ` kubectl describe {{[po| pods]}} {{pod_name}} {{[-n|--namespace]}} {{namespace}} `
17
17
18
18
- Show the details of a specific node in a namespace:
19
19
20
- ` kubectl describe nodes {{node_name}} {{[-n|--namespace]}} {{namespace}} `
20
+ ` kubectl describe {{[no| nodes]}} {{node_name}} {{[-n|--namespace]}} {{namespace}} `
21
21
22
22
- Show details of Kubernetes objects defined in a YAML manifest file:
23
23
Original file line number Diff line number Diff line change 5
5
6
6
- Apply taint to a node:
7
7
8
- ` kubectl taint nodes {{node_name}} {{label_key}}={{label_value}}:{{effect}} `
8
+ ` kubectl taint {{[no| nodes]}} {{node_name}} {{label_key}}={{label_value}}:{{effect}} `
9
9
10
10
- Remove taint from a node:
11
11
12
- ` kubectl taint nodes {{node_name}} {{label_key}}:{{effect}}- `
12
+ ` kubectl taint {{[no| nodes]}} {{node_name}} {{label_key}}:{{effect}}- `
13
13
14
14
- Remove all taints from a node:
15
15
16
- ` kubectl taint nodes {{node_name}} {{label_key}}- `
16
+ ` kubectl taint {{[no| nodes]}} {{node_name}} {{label_key}}- `
You can’t perform that action at this time.
0 commit comments