fixing regex, ready for tests
This commit is contained in:
26
compose/compose.go
Normal file
26
compose/compose.go
Normal file
@@ -0,0 +1,26 @@
|
||||
package compose
|
||||
|
||||
type RestartConfig struct {
|
||||
Condition *string `yaml:"condition"`
|
||||
Delay *string `yaml:"delay"`
|
||||
MaxAttempts *int `yaml:"max_attempts"`
|
||||
Window *string `yaml:"window"`
|
||||
}
|
||||
|
||||
type DeployConfig struct {
|
||||
Policy *RestartConfig `yaml:"restart_policy"`
|
||||
}
|
||||
|
||||
type ServiceConfig struct {
|
||||
MemLimit *string `yaml:"mem_limit"`
|
||||
Cpus *float64 `yaml:"cpus"`
|
||||
Ports *[]string `yaml:"ports"`
|
||||
User *string `yaml:"user"`
|
||||
Deploy *DeployConfig `yaml:"deploy"`
|
||||
SecOpts *[]string `yaml:"security_opt"`
|
||||
Privileged *bool `yaml:"privileged"`
|
||||
}
|
||||
|
||||
type Compose struct {
|
||||
Services map[string]ServiceConfig `yaml:"services"`
|
||||
}
|
||||
Reference in New Issue
Block a user