Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for NestedStringMap (0.07 sec)

  1. istioctl/pkg/validate/validate.go

    func GetTemplateLabels(u *unstructured.Unstructured) (map[string]string, error) {
    	if spec, ok := u.Object["spec"].(map[string]any); ok {
    		if template, ok := spec["template"].(map[string]any); ok {
    			m, _, err := unstructured.NestedStringMap(template, "metadata", "labels")
    			if err != nil {
    				return nil, err
    			}
    			return m, nil
    		}
    	}
    	return nil, nil
    }
    
    Registered: Wed Nov 06 22:53:10 UTC 2024
    - Last Modified: Thu Aug 15 22:27:47 UTC 2024
    - 14.3K bytes
    - Viewed (0)
Back to top