// GetSecret returns the secret identified by the key
GetSecret returns the secret identified by the key
// GetSecret returns the secret identified by the key
func (c *Context) GetSecret(secretKey string) *v1.Secret {
	secretInterface, exist, err := c.Caches.Secret.GetByKey(secretKey)
	if err != nil {
		glog.V(1).Infof("unable to get secret from store, error occured %s", err.Error())
		return nil
	}
	if !exist {
		glog.V(1).Infof("unable to get secret from store, no such service %s", secretKey)
		return nil
	}
	secret := secretInterface.(*v1.Secret)
	return secret
}
func ( c * Context ) GetSecret ( secretKey string ) * v1 . Secret { secretInterface , exist , err := c . Caches . Secret . GetByKey ( secretKey ) if err != nil { glog . V ( 1 ) . Infof ( " " , err . Error ( ) ) return nil } if ! exist { glog . V ( 1 ) . Infof ( " " , secretKey ) return nil } secret := secretInterface . ( * v1 . Secret ) return secret }
GetSecret returns the secret identified by the key
GetSecret returns the secret identified by the key