Skip to content

Instantly share code, notes, and snippets.

@jayunit100
Created March 15, 2017 14:38
Show Gist options
  • Save jayunit100/26db02a8b30f70141acbf7d1b44481f0 to your computer and use it in GitHub Desktop.
Save jayunit100/26db02a8b30f70141acbf7d1b44481f0 to your computer and use it in GitHub Desktop.
// Ignore all calls to subresources or resources other than pods.
- if len(attributes.GetSubresource()) != 0 || attributes.GetResource().GroupResource() != api.Resource("pods") {
+ if len(attributes.GetSubresource()) != 0 || attributes.GetResource().GroupResource() != api.Resource("nodes") {
return nil
}
- pod, ok := attributes.GetObject().(*api.Pod)
+ pod, ok := attributes.GetObject().(*api.Node)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment