Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

kubectl patch annotation

#Replace the forward slash (/) in kubernetes.io/ingress.class with ~1.
#Your command should look like this,

$ kubectl patch ingress mying --type='json' -p='[{"op": "add", "path": "/metadata/annotations/kubernetes.io~1ingress.class", "value":"nginx"}]'
#Reference: RFC 6901 https://www.rfc-editor.org/rfc/rfc6901#section-3
Comment

kubectl patch annotation

#much easier for me was to annotate rather than patch:

kubectl annotate ingress mying kubernetes.io/ingress.class=value --dry-run=client -o yaml
kubectl annotate ingress mying kubernetes.io/ingress.class=value

#add --dry-run -o yaml flags if you want to test it before applying the change.
Comment

kubectl patch annotation on pods

#Patch deployment adding annotation to disable istio sidecar injection 

kubectl patch deployment nginx -p '{"spec": {"template":{"metadata":{"annotations":{"sidecar.istio.io/inject":"false"}}}} }'
Comment

PREVIOUS NEXT
Code Example
Shell :: git stash changes to particular file 
Shell :: git rename working branch 
Shell :: install gdal django rest 
Shell :: check app installed with brew 
Shell :: git push branch 
Shell :: install gulp gulp-util exited with code 1 
Shell :: how to setup pre commit hook on my local 
Shell :: linux get part of string 
Shell :: update cordov ios 
Shell :: jq unencode string 
Shell :: photoview github 
Shell :: install with pip in jupyter 
Shell :: generate zip file terminal 
Shell :: java.util.concurrent.ExecutionException: com.android.builder.testing.api.DeviceException: com.android.ddmlib.InstallException: INSTALL_FAILED_VERSION_DOWNGRADE: Package Verification Result 
Shell :: ncrack ftp brute force 
Shell :: terminal multiple commands 
Shell :: relead ngix 
Shell :: have all changes from a local branch to a new local branch git 
Shell :: powershell import-certificate trusted publisher 
Shell :: react native cannot load 
Shell :: LINUX STRING TO UPPERCASE 
Shell :: bash if with function call 
Shell :: rsync delete old files 
Shell :: linux kill ssh connection 
Shell :: How to delete dir, subdirectory, fils all in cmd 
Shell :: save terminal output to file with script 
Shell :: git merge conflict resolve 
Shell :: npm install from git 
Shell :: bash escape all special characters 
Shell :: how to uninstall django 
ADD CONTENT
Topic
Content
Source link
Name
2+9 =