* Adds metadata to the knative spec in the generation command * Fixes: #815 Tested by running locally and verifying it matched the request from @Jeff-Lowrey faas-cli generate \ --api=serving.knative.dev/v1alpha1 \ --annotation sidecar.istio.io/inject=true This also works when bringing in annotations from the YAML file. Signed-off-by: Alex Ellis (OpenFaaS Ltd) <alexellis2@gmail.com>
12 lines
419 B
Go
12 lines
419 B
Go
// Copyright (c) OpenFaaS Author(s) 2018. All rights reserved.
|
|
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
|
|
package schema
|
|
|
|
// Metadata metadata of the object
|
|
type Metadata struct {
|
|
Name string `yaml:"name,omitempty"`
|
|
Namespace string `yaml:"namespace,omitempty"`
|
|
Annotations map[string]string `yaml:"annotations,omitempty"`
|
|
}
|