70 lines
1.8 KiB
Go
70 lines
1.8 KiB
Go
package main
|
|
|
|
const DEPLOYMENT_NAME_SUFFIX = "navi-service"
|
|
|
|
type Deployment struct {
|
|
Name string `json:"name"`
|
|
NameSuffix string
|
|
}
|
|
|
|
type Manifest struct {
|
|
ExtraResources ExtraResources `json:"extraResources"`
|
|
Team Team `json:"team"`
|
|
Deployment Deployment `json:"deployment"`
|
|
StateStoreBackend StateStoreBackend
|
|
}
|
|
|
|
type ExtraResources struct {
|
|
Environment string `json:"environment"`
|
|
Workspace string
|
|
Database Database `json:"database"`
|
|
ServiceRole ServiceRole `json:"aws_access"`
|
|
S3Buckets []S3Bucket `json:"s3_buckets"`
|
|
}
|
|
|
|
//We provide defaults in respective terraforms instead of here to keep all values at one place
|
|
type Database struct {
|
|
AwsInstanceClass string `json:"awsInstanceClass"`
|
|
PsqlFamily string `json:"psqlFamily"`
|
|
PsqlEngineVersion string `json:"psqlEngineVersion"`
|
|
User string `json:"user"`
|
|
Password string `json:"password"`
|
|
SizeInGb int `json:"sizeInGb"`
|
|
DbNames []string `json:"dbNames"`
|
|
InstanceName string `json:"instanceName"`
|
|
BackupDisabled bool `json:"backupDisabled"`
|
|
MultiAZDisabled bool `json:"multiAZDisabled"`
|
|
}
|
|
|
|
type Team struct {
|
|
Name string `json:"name"`
|
|
}
|
|
|
|
type Policies struct {
|
|
Actions []string `json:"actions"`
|
|
Resource string `json:"resource"`
|
|
}
|
|
|
|
type ServiceRole struct {
|
|
Policies []Policies `json:"policies"`
|
|
}
|
|
|
|
type StateStoreBackend struct {
|
|
BucketName string
|
|
AWSProfile string
|
|
}
|
|
|
|
type S3Bucket struct {
|
|
BucketName string `json:"anonymizedBucketName"`
|
|
BucketTag string `json:"bucketTag"`
|
|
LifecycleRules []LifecycleRule `json:"lifecycleRules"`
|
|
}
|
|
|
|
type LifecycleRule struct {
|
|
Enabled bool `json:"enabled"`
|
|
ObjectExpiration ObjectExpiration `json:"expiration"`
|
|
}
|
|
|
|
type ObjectExpiration struct {
|
|
Days int `json:"days"`
|
|
} |