forked from ehazlett/shipyard
-
Notifications
You must be signed in to change notification settings - Fork 0
/
extension.go
29 lines (27 loc) · 1.63 KB
/
extension.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
package shipyard
import "github.com/citadel/citadel"
type (
Extension struct {
ID string `json:"id,omitempty" gorethink:"id,omitempty"`
Name string `json:"name,omitempty" gorethink:"name"`
Image string `json:"image,omitempty" gorethink:"image"`
Author string `json:"author,omitempty" gorethink:"author"`
Description string `json:"description,omitempty" gorethink:"description"`
Version string `json:"version,omitempty" gorethink:"version"`
Url string `json:"url,omitempty" gorethink:"url"`
Config ExtensionConfig `json:"config" gorethink:"config"`
}
ExtensionConfig struct {
ContainerName string `json:"container_name,omitempty" gorethink:"container_name"`
Cpus float64 `json:"cpus,omitempty" gorethink:"cpus"`
Memory float64 `json:"memory,omitempty" gorethink:"memory"`
Environment map[string]string `json:"environment,omitempty" gorethink:"environment"`
Links map[string]string `json:"links,omitempty" gorethink:"links"`
Args []string `json:"args,omitempty" gorethink:"args"`
Volumes []string `json:"volumes,omitempty" gorethink:"volumes"`
Ports []*citadel.Port `json:"ports,omitempty" gorethink:"ports"`
DeployPerEngine bool `json:"deploy_per_engine" gorethink:"deploy_per_engine"`
PromptArgs []string `json:"prompt_args,omitempty" gorethink:"prompt_args"`
PromptEnvironment []string `json:"prompt_env,omitempty" gorethink:"prompt_env"`
}
)