Documentation
¶
Overview ¶
Copyright © 2020 Vertigo Tecnologia. All rights reserved. Licensed under the Apache License, Version 2.0. See LICENSE file in the project root for full license information.
Copyright © 2020 Vertigo Tecnologia. All rights reserved. Licensed under the Apache License, Version 2.0. See LICENSE file in the project root for full license information.
Copyright © 2020 Vertigo Tecnologia. All rights reserved. Licensed under the Apache License, Version 2.0. See LICENSE file in the project root for full license information.
Index ¶
- func AppendFunction(function Function) error
- func CreateTemplate(function Function) error
- func GetAllFunctions() (map[string]Function, error)
- func GetStackFileName() string
- func ParseYAMLForLanguageTemplate(fileName string) (fileData []byte, err error)
- func RemoveFunction(functionName string, removeFolder, verboseFlag bool) error
- type Build
- type Config
- type ConfigFromPlugin
- type CpuMemory
- type Function
- type Plugin
- type Provider
- type SecretKeyRef
- type Stack
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AppendFunction ¶
func CreateTemplate ¶
func GetAllFunctions ¶
func GetStackFileName ¶ added in v0.0.12
func GetStackFileName() string
func RemoveFunction ¶ added in v0.0.8
Types ¶
type Config ¶
type Config struct { Build Build `yaml:"build,omitempty"` Scale struct { Min string `yaml:"min"` Max string `yaml:"max"` } `yaml:"scale,omitempty"` // Resource limit that the function will use Limits CpuMemory `yaml:"limits,omitempty"` // Minimum resource required that the function will use Requests CpuMemory `yaml:"requests,omitempty"` // Environment variables Environments map[string]interface{} `yaml:"environments,omitempty"` }
Config apply one or all functions in stack.yaml
type ConfigFromPlugin ¶ added in v0.0.9
type ConfigFromPlugin struct {
SecretKeyRef SecretKeyRef `yaml:"secretKeyRef,omitempty"`
}
type Function ¶
type Function struct { // Name of deployed function Name string `yaml:"-"` // Lang/Template name Lang string `yaml:"lang"` // Handler Local folder to use for function Handler string `yaml:"handler"` // Docker image name Image string `yaml:"image"` // Path Path string `yaml:"path,omitempty"` // Config FunctionConfig Config `yaml:"config,omitempty"` // Kong Plugins Plugins map[string]Plugin `yaml:"plugins,omitempty"` }
Function as deployed or built on FaaS
type Plugin ¶ added in v0.0.9
type Plugin struct { // Plugin name Name string `yaml:"-"` // Plugin type Type string `yaml:"type,omitempty"` Global string `yaml:"global,omitempty"` Config map[string]interface{} `yaml:"config,omitempty"` ConfigFrom ConfigFromPlugin `yaml:"configFrom,omitempty"` }
type SecretKeyRef ¶ added in v0.0.9
type Stack ¶
type Stack struct { Version string `yaml:"version,omitempty"` Provider Provider `yaml:"provider,omitempty"` Hostname string `yaml:"hostname,omitempty"` Functions map[string]Function `yaml:"functions,omitempty"` StackConfig Config `yaml:"config,omitempty"` Custom []string `yaml:"custom,omitempty"` }
Stack root level YAML file to define FaaS function-set