-
Notifications
You must be signed in to change notification settings - Fork 0
/
models.go
49 lines (41 loc) · 1.5 KB
/
models.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
package qa
type ServerlessYML struct {
FrameworkVersion string `yaml:"frameworkVersion"`
Provider ServerlessProviderDefinition `yaml:"provider"`
Functions map[string]ServerlessFunctionDefinition `yaml:"functions"`
Resources ServerlessResource `yaml:"resources"`
}
type ServerlessProviderDefinition struct {
Name string `yaml:"name"`
Stage string `yaml:"stage"`
Runtime string `yaml:"runtime"`
Architecture string `yaml:"architecture"`
Region string `yaml:"region"`
Environment map[string]string `yaml:"environment"`
}
type ServerlessFunctionDefinition struct {
MemorySize int `yaml:"memorySize"`
Timeout int `yaml:"timeout"`
Handler string `yaml:"handler"`
Package ServerlessPackageDefinition `yaml:"package"`
Events []interface{} `yaml:"events"`
Environment map[string]string `yaml:"environment"`
}
type ServerlessResource struct {
Definitions map[string]ServerlessResourceDefinition `yaml:"Resources"`
}
type ServerlessResourceDefinition struct {
Type string `yaml:"Type"`
Properties map[string]any `yaml:"Properties"`
}
type ServerlessPackageDefinition struct {
Artifact string `yaml:"artifact"`
}
type ResourceInfo struct {
Path string
File string
}
type FunctionInfo struct {
Path string
File string
}