Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

kubectl update field

# Partially update a node using strategic merge patch
kubectl patch node k8s-node-1 -p '{"spec":{"unschedulable":true}}'

# Partially update a node identified by the type and name specified in "node.json" using strategic merge patch
kubectl patch -f node.json -p '{"spec":{"unschedulable":true}}'

# Update a container's image; spec.containers[*].name is required because it's a merge key
kubectl patch pod valid-pod -p '{"spec":{"containers":[{"name":"kubernetes-serve-hostname","image":"new image"}]}}'

# Update a container's image using a json patch with positional arrays
kubectl patch pod valid-pod -type='json' -p='[{"op": "replace", "path": "/spec/containers/0/image", "value":"new image"}]'
Comment

PREVIOUS NEXT
Code Example
Shell :: awk print only range of lines 
Shell :: awk line range 
Shell :: sudo show asterisks 
Shell :: bash redirect stderr to null 
Shell :: To copy a file from B to A while logged into A: 
Shell :: how to create tls.crt and tls.key 
Shell :: find size delete bash 
Shell :: bash run until success or timeout 
Shell :: check container logging driver 
Shell :: apt install youtube-dl 
Shell :: add vimplug 
Shell :: purge opencv ubuntu 20.04 
Shell :: firewalld redhat 
Shell :: git credential.helper does not store username password 
Shell :: docker compose command 
Shell :: webdriver-manager install in mac 
Shell :: gitconfig includeif example 
Shell :: non-docker root 
Shell :: how to remove directory with contents in w10 cmd 
Shell :: start confluence service ubuntu 
Shell :: resize all images in folder linux 
Shell :: View a Particular Commit in git command 
Shell :: install graphene 
Shell :: android connect your phone via usb on linux - adb devices 
Shell :: zsh open current directory in explorer 
Shell :: pip3 install requirements.txt 
Shell :: sh how to not store a command in history 
Shell :: install conky on pop os 
Shell :: Can we install XAMPP on Linux from a given link 
Shell :: snapcraft 
ADD CONTENT
Topic
Content
Source link
Name
7+8 =