Show kind in resource-not-found-in-release error

This error occures when resource is not found in helm release:
`Error: UPGRADE FAILED: no resource with the name "redis-cluster-sentinel" found`

Changed to:
`Error: UPGRADE FAILED: no ConfigMap with the name "redis-cluster-sentinel" found`

So now that resource can easily be found in cluster.
pull/3302/head
Timofey Kirillov 7 years ago
parent 8a59aed59f
commit 13cb8d8244

@ -274,7 +274,8 @@ func (c *Client) Update(namespace string, originalReader, targetReader io.Reader
originalInfo := original.Get(info) originalInfo := original.Get(info)
if originalInfo == nil { if originalInfo == nil {
return fmt.Errorf("no resource with the name %q found", info.Name) kind := info.Mapping.GroupVersionKind.Kind
return fmt.Errorf("no %s with the name %q found", kind, info.Name)
} }
if err := updateResource(c, info, originalInfo.Object, force, recreate); err != nil { if err := updateResource(c, info, originalInfo.Object, force, recreate); err != nil {

Loading…
Cancel
Save