Documentation
¶
Index ¶
- type Claims
- type DeploymentStrategyInput
- type Environment
- type EnvironmentInput
- type ExtConfig
- type Extension
- type ExtensionInput
- type Feature
- type HealthProbeHttpHeaderInput
- type JSON
- type Model
- type PaginatorInput
- type PermissionInput
- type Project
- type ProjectBookmark
- type ProjectEnvironment
- type ProjectEnvironmentInput
- type ProjectEnvironmentsInput
- type ProjectExtension
- type ProjectExtensionInput
- type ProjectInput
- type ProjectSearchInput
- type ProjectSettings
- type Release
- type ReleaseExtension
- type ReleaseInput
- type Secret
- type SecretInput
- type SecretScope
- type SecretValue
- type Service
- type ServiceDeploymentStrategy
- type ServiceHealthProbe
- type ServiceHealthProbeHttpHeader
- type ServiceHealthProbeInput
- type ServiceInput
- type ServicePort
- type ServicePortInput
- type ServiceSpec
- type ServiceSpecInput
- type User
- type UserPermission
- type UserPermissionsInput
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Claims ¶
type Claims struct {
UserID string `json:"userID"`
Email string `json:"email"`
Verified bool `json:"email_verified"`
Groups []string `json:"groups"`
Permissions []string `json:"permissions"`
TokenError string `json:"tokenError"`
}
Claims
type DeploymentStrategyInput ¶
type Environment ¶
type Environment struct {
Model `json:",inline"`
// Name
Name string `json:"name"`
// Key
Key string `json:"key"`
// Is Default
IsDefault bool `json:"isDefault"`
// Color
Color string `json:"color"`
}
Environment Environment
type EnvironmentInput ¶
type EnvironmentInput struct {
// ID
ID *string `json:"id"`
// Name
Name string `json:"name"`
// Key
Key string `json:"key"`
// IsDefault
IsDefault bool `json:"isDefault"`
// Color
Color string `json:"color"`
}
EnvironmentInput
type ExtConfig ¶
type ExtConfig struct {
Key string `json:"key"`
Value string `json:"value"`
Secret bool `json:"secret"`
AllowOverride bool `json:"allowOverride"`
}
ExtConfig
type Extension ¶
type Extension struct {
Model `json:",inline"`
// Type
Type plugins.Type `json:"type"`
// Key
Key string `json:"key"`
// Name
Name string `json:"name"`
// Component
Component string `json:"component"`
// EnvironmentID
EnvironmentID uuid.UUID `bson:"environmentID" json:"environmentID" gorm:"type:uuid"`
// Config
Config postgres.Jsonb `json:"config" gorm:"type:jsonb;not null"`
}
Extension spec
type ExtensionInput ¶
type ExtensionInput struct {
// ID
ID *string `json:"id"`
// Name
Name string `json:"name"`
// Key
Key string `json:"key"`
// Component
Component string `json:"component"`
// EnvironmentID
EnvironmentID string `json:"environmentID"`
// Config
Config JSON `json:"config"`
// Type
Type string `json:"type"`
}
ExtensionInput
type Feature ¶
type Feature struct {
Model `json:",inline"`
// ProjectID
ProjectID uuid.UUID `bson:"projectID" json:"projectID" gorm:"type:uuid"`
// Message
Message string `json:"message"`
// User
User string `json:"user"`
// Hash
Hash string `json:"hash"`
// ParentHash
ParentHash string `json:"parentHash"`
// Ref
Ref string `json:"ref"`
// Created
Created time.Time `json:"created"`
}
Feature
type JSON ¶
type JSON struct {
json.RawMessage
}
JSON
func (*JSON) ImplementsGraphQLType ¶
func (*JSON) UnmarshalGraphQL ¶
type Model ¶
type Model struct {
// ID
ID uuid.UUID `sql:"type:uuid;default:uuid_generate_v4()" json:"id" gorm:"primary_key"`
// CreatedAt
CreatedAt time.Time `json:"createdAt"`
// UpdatedAt
UpdatedAt time.Time `json:"updatedAt"`
// DeletedAt
DeletedAt *time.Time `json:"deletedAt" sql:"index"`
}
Default fields for a model
type PaginatorInput ¶
type PaginatorInput struct {
// Page
Page *int32 `json:"page"`
// Limit
Limit *int32 `json:"limit"`
}
PaginatorInput
type PermissionInput ¶
PermissionInput
type Project ¶
type Project struct {
Model `json:",inline"`
// Name
Name string `json:"name"`
// Slug
Slug string `json:"slug"`
// Repository
Repository string `json:"repository"`
// Secret
Secret string `json:"-"`
// GitUrl
GitUrl string `json:"GitUrl"`
// GitProtocol
GitProtocol string `json:"GitProtocol"`
// RsaPrivateKey
RsaPrivateKey string `json:"-"`
// RsaPublicKey
RsaPublicKey string `json:"rsaPublicKey"`
}
Project
type ProjectBookmark ¶
type ProjectBookmark struct {
Model `json:"inline"`
// UserID
UserID uuid.UUID `json:"userID" gorm:"type:uuid"`
// ProjectID
ProjectID uuid.UUID `json:"projectID" gorm:"type:uuid"`
}
ProjectEnvironment
type ProjectEnvironment ¶
type ProjectEnvironment struct {
Model `json:"inline"`
// EnvironmentID
EnvironmentID uuid.UUID `json:"environmentID" gorm:"type:uuid"`
// ProjectID
ProjectID uuid.UUID `json:"projectID" gorm:"type:uuid"`
}
ProjectEnvironment
type ProjectEnvironmentInput ¶
type ProjectEnvironmentInput struct {
EnvironmentID string `json:"environmentID"`
Grant bool `json:"grant"`
}
ProjectEnvironmentInput
type ProjectEnvironmentsInput ¶
type ProjectEnvironmentsInput struct {
ProjectID string `json:"projectID"`
Permissions []ProjectEnvironmentInput `json:"permissions"`
}
ProjectEnvironmentsInput
type ProjectExtension ¶
type ProjectExtension struct {
Model `json:",inline"`
// ProjectID
ProjectID uuid.UUID `json:"projectID" gorm:"type:uuid"`
// ExtensionID
ExtensionID uuid.UUID `json:"extID" gorm:"type:uuid"`
// State
State transistor.State `json:"state"`
// StateMessage
StateMessage string `json:"stateMessage"`
// Artifacts
Artifacts postgres.Jsonb `json:"artifacts" gorm:"type:jsonb"`
// Config
Config postgres.Jsonb `json:"config" gorm:"type:jsonb;not null"`
// CustomConfig
CustomConfig postgres.Jsonb `json:"customConfig" gorm:"type:jsonb;not null"`
// EnvironmentID
EnvironmentID uuid.UUID `bson:"environmentID" json:"environmentID" gorm:"type:uuid"`
}
ProjectExtension
type ProjectExtensionInput ¶
type ProjectExtensionInput struct {
// ID
ID *string `json:"id"`
// ProjectID
ProjectID string `json:"projectID"`
// ExtensionID
ExtensionID string `json:"extID"`
// Config
Config JSON `json:"config"`
// CustomConfig
CustomConfig JSON `json:"customConfig"`
// EnvironmentID
EnvironmentID string `json:"environmentID"`
}
ProjectExtensionInput
type ProjectInput ¶
type ProjectInput struct {
// ID
ID *string `json:"id"`
// GitProtocol
GitProtocol string `json:"gitProtocol"`
// GitUrl
GitUrl string `json:"gitUrl"`
// GitBranch
GitBranch *string `json:"gitBranch"`
// Bookmarked
Bookmarked *bool `json:"bookmarked"`
// ContinuousDeploy
ContinuousDeploy *bool `json:"continuousDeploy"`
// EnvironmentID
EnvironmentID *string `json:"environmentID"`
}
ProjectInput
type ProjectSearchInput ¶
type ProjectSearchInput struct {
// Repository
Repository *string `json:"repository"`
// Bookmarked
Bookmarked bool `json:"bookmarked"`
}
ProjectSearchInput
type ProjectSettings ¶
type ProjectSettings struct {
Model `json:"inline"`
// EnvironmentID
EnvironmentID uuid.UUID `json:"environmentID" gorm:"type:uuid"`
// ProjectID
ProjectID uuid.UUID `json:"projectID" gorm:"type:uuid"`
// GitBranch
GitBranch string `json:"gitBranch"`
//ContinuousDeploy
ContinuousDeploy bool `json:"continuousDeploy"`
}
Project settings
type Release ¶
type Release struct {
Model `json:",inline"`
// State
State transistor.State `json:"state"`
// StateMessage
StateMessage string `json:"stateMessage"`
// ProjectID
ProjectID uuid.UUID `json:"projectID" gorm:"type:uuid"`
// User
User User
// UserID
UserID uuid.UUID `json:"userID" gorm:"type:uuid"`
// HeadFeatureID
HeadFeatureID uuid.UUID `json:"headFeatureID" gorm:"type:uuid"`
// TailFeatureID
TailFeatureID uuid.UUID `json:"tailFeatureID" gorm:"type:uuid"`
// Services
Services postgres.Jsonb `json:"services" gorm:"type:jsonb;"`
// Secrets
Secrets postgres.Jsonb `json:"secrets" gorm:"type:jsonb;"`
// ProjectExtensions
ProjectExtensions postgres.Jsonb `json:"extensions" gorm:"type:jsonb;"`
// EnvironmentID
EnvironmentID uuid.UUID `json:"environmentID" gorm:"type:uuid"`
// Started
Started time.Time
// Finished
Finished time.Time
// ForceRebuild
ForceRebuild bool `json:"forceRebuild"`
IsRollback bool `json:"isRollback"`
}
Release
type ReleaseExtension ¶
type ReleaseExtension struct {
Model `json:",inline"`
// ReleaseID
ReleaseID uuid.UUID `json:"releaseID" gorm:"type:uuid"`
// FetureHash
FeatureHash string `json:"featureHash"`
// ServicesSignature
ServicesSignature string `json:"servicesSignature"`
// SecretsSignature
SecretsSignature string `json:"secretsSignature"`
// ProjectExtensionID
ProjectExtensionID uuid.UUID `json:"extensionID" gorm:"type:uuid"`
// State
State transistor.State `json:"state"`
// StateMessage
StateMessage string `json:"stateMessage"`
// Type
Type plugins.Type `json:"type"`
// Artifacts
Artifacts postgres.Jsonb `json:"artifacts" gorm:"type:jsonb"` // captured on workflow success/ fail
// Finished
Finished time.Time
// Started
Started time.Time
}
ReleaseExtension
type ReleaseInput ¶
type ReleaseInput struct {
// ID
ID *string `json:"id"`
// HeadFeatureID
HeadFeatureID string `json:"headFeatureID"`
// ProjectID
ProjectID string `json:"projectID"`
// EnvironmentID
EnvironmentID string `json:"environmentID"`
// ForceRebuild
ForceRebuild bool `json:"forceRebuild"`
}
ReleaseInput
type Secret ¶
type Secret struct {
Model `json:",inline"`
// Key
Key string `json:"key"`
// Value
Value SecretValue `json:"value"`
// Type
Type plugins.Type `json:"type"`
// ProjectID
ProjectID uuid.UUID `bson:"projectID" json:"projectID" gorm:"type:uuid"`
// Scope
Scope SecretScope `json:"scope"`
// EnvironmentID
EnvironmentID uuid.UUID `bson:"environmentID" json:"environmentID" gorm:"type:uuid"`
// IsSecret
IsSecret bool `json:"isSecret"`
}
Secret
type SecretInput ¶
type SecretInput struct {
// ID
ID *string `json:"id"`
// Key
Key string `json:"key"`
// Value
Value string `json:"value"`
// Type
Type string `json:"type"`
// Scope
Scope string `json:"scope"`
// ProjectID
ProjectID *string `json:"projectID"`
// EnvironmentID
EnvironmentID string `json:"environmentID"`
// IsSecret
IsSecret bool `json:"isSecret"`
}
SecretInput
type SecretScope ¶
type SecretScope string
type SecretValue ¶
type Service ¶
type Service struct {
Model `json:",inline"`
// ProjectID
ProjectID uuid.UUID `bson:"projectID" json:"projectID" gorm:"type:uuid"`
// ServiceSpecID
ServiceSpecID uuid.UUID `bson:"serviceSpecID" json:"serviceSpecID" gorm:"type:uuid"`
// Command
Command string `json:"command"`
// Name
Name string `json:"name"`
// Type
Type plugins.Type `json:"type"`
// Count
Count int32 `json:"count,string"`
// Ports
Ports []ServicePort `json:"servicePorts"`
// EnvironmentID
EnvironmentID uuid.UUID `bson:"environmentID" json:"environmentID" gorm:"type:uuid"`
// DeploymentStrategy
DeploymentStrategy ServiceDeploymentStrategy `json:"deploymentStrategy"`
// ReadinessProbe
ReadinessProbe ServiceHealthProbe `json:"readinessProbe"`
// LivenessProbe
LivenessProbe ServiceHealthProbe `json:"livenessProbe"`
// PreStopHook
PreStopHook string `json:"preStopHook"`
}
Service
type ServiceDeploymentStrategy ¶
type ServiceDeploymentStrategy struct {
// Model
Model `json:",inline"`
// ServiceID
ServiceID uuid.UUID `bson:"serviceID" json:"-" gorm:"type:uuid"`
// Type
Type plugins.Type `json:"type"`
MaxUnavailable int32 `json:"maxUnavailable"`
// MaxSurge
MaxSurge int32 `json:"maxSurge"`
}
DeploymentStrategy
type ServiceHealthProbe ¶
type ServiceHealthProbe struct {
// Model
Model `json:",inline"`
// ServiceID
ServiceID uuid.UUID `bson:"serviceID" json:"-" gorm:"type:uuid"`
// Type: required; accepts `readinessProbe` and `livenessProbe`
Type plugins.Type `json:"type"`
// Method: required; accepts `exec`, `http`, and `tcp`
Method string `json:"method"`
// Command: Required with Method `exec`
Command string `json:"command"`
// Port: Required with Method `http` or `tcp`
Port int32 `json:"port"`
// Scheme: required with method `http`; accepts `http` or `https`
Scheme string `json:"scheme"`
// Path: required with Method `http`
Path string `json:"path"`
//HTTPHeaders is a slice of HTTP headers used by http probes
HttpHeaders []ServiceHealthProbeHttpHeader `json:"httpHeaders"`
// InitialDelaySeconds is the delay before the probe begins to evaluate service health
InitialDelaySeconds int32 `json:"initialDelaySeconds"`
// PeriodSeconds is how frequently the probe is executed
PeriodSeconds int32 `json:"periodSeconds"`
// TimeoutSeconds is the number of seconds before the probe times out
TimeoutSeconds int32 `json:"timeoutSeconds"`
// SuccessThreshold minimum consecutive success before the probe is considered successfull
SuccessThreshold int32 `json:"successThreshold"`
// FailureThreshold is the number of attempts before a probe is considered failed
FailureThreshold int32 `json:"failureThreshold"`
}
ServiceHealthProbe
type ServiceHealthProbeInput ¶
type ServiceHealthProbeInput struct {
// Type currently supports ReadinessProbe and LivenessProbe
Type *plugins.Type `json:"type"`
//Method supports `exec`, `http`, and `tcp`
Method string `json:"method"`
// Command is only evaluated if Method is `exec`
Command *string `json:"command"`
// Port is only evaluated if Method is either `http` or `tcp`
Port *int32 `json:"port,string"`
// Scheme accepts `http` or `https` - it is only evaluated if Method is `http`
Scheme *string `json:"scheme"`
// Path is only evaluated if Method is `http`
Path *string `json:"path"`
// InitialDelaySeconds is the delay before the probe begins to evaluate service health
InitialDelaySeconds *int32 `json:"initialDelaySeconds,string"`
// PeriodSeconds is how frequently the probe is executed
PeriodSeconds *int32 `json:"periodSeconds,string"`
// TimeoutSeconds is the number of seconds before the probe times out
TimeoutSeconds *int32 `json:"timeoutSeconds,string"`
// SuccessThreshold minimum consecutive success before the probe is considered successfull
SuccessThreshold *int32 `json:"successThreshold,string"`
// FailureThreshold is the number of attempts before a probe is considered failed
FailureThreshold *int32 `json:"failureThreshold,string"`
// HealthProbeHttpHeaders
HttpHeaders *[]HealthProbeHttpHeaderInput `json:"httpHeaders"`
}
ServiceHealthProbe is used for readiness/liveness health checks for services Further documentation can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/
type ServiceInput ¶
type ServiceInput struct {
// ID
ID *string `json:"id"`
// ProjectID
ProjectID string `json:"projectID"`
// Command
Command string `json:"command"`
// Name
Name string `json:"name"`
// ServiceSpecID
ServiceSpecID string `json:"serviceSpecID"`
// Count
Count int32 `json:"count,string"`
// ContainerPorts
Ports *[]ServicePortInput `json:"ports"`
// Type
Type string `json:"type"`
// EnvironmentID
EnvironmentID string `json:"environmentID"`
// DeploymentStrategy
DeploymentStrategy *DeploymentStrategyInput `json:"deploymentStrategy"`
// ReadinessProbe
ReadinessProbe *ServiceHealthProbeInput `json:"readinessProbe"`
// LivenessProbe
LivenessProbe *ServiceHealthProbeInput `json:"livenessProbe"`
// PreStopHook
PreStopHook *string `json"preStopHook"`
}
ServiceInput
type ServicePort ¶
type ServicePort struct {
Model `json:",inline"`
// ServiceID
ServiceID uuid.UUID `bson:"serviceID" json:"-" gorm:"type:uuid"`
// Protocol
Protocol string `json:"protocol"`
// Port
Port int32 `json:"port"`
}
ServicePort
type ServicePortInput ¶
type ServicePortInput struct {
// Port
Port int32 `json:"port,string"`
// Protocol
Protocol string `json:"protocol"`
}
ServicePortInput
type ServiceSpec ¶
type ServiceSpec struct {
Model `json:",inline"`
// Name
Name string `json:"name"`
// CpuRequest
CpuRequest string `json:"cpuRequest"`
// CpuLimit
CpuLimit string `json:"cpuLimit"`
// MemoryRequest
MemoryRequest string `json:"memoryRequest"`
// MemoryLimit
MemoryLimit string `json:"memoryLimit"`
// TerminationGracePeriod
TerminationGracePeriod string `json:"terminationGracePeriod"`
}
ServiceSpec
type ServiceSpecInput ¶
type ServiceSpecInput struct {
// ID
ID *string `json:"id"`
// Name
Name string `json:"name"`
// CpuRequest
CpuRequest string `json:"cpuRequest"`
// CpuLimit
CpuLimit string `json:"cpuLimit"`
// MemoryRequest
MemoryRequest string `json:"memoryRequest"`
// MemoryLimit
MemoryLimit string `json:"memoryLimit"`
// TerminationGracePeriod
TerminationGracePeriod string `json:"terminationGracePeriod"`
}
ServiceSpecInput
type User ¶
type User struct {
Model `json:",inline"`
// Email
Email string `json:"email"`
// Password
Password string `json:"password" gorm:"type:varchar(255)"`
// Permissions
Permissions []UserPermission `json:"permissions"`
}
User
type UserPermission ¶
type UserPermission struct {
Model `json:",inline"`
// UserID
UserID uuid.UUID `json:"userID" gorm:"type:uuid"`
// Value
Value string `json:"value"`
}
User permission
type UserPermissionsInput ¶
type UserPermissionsInput struct {
UserID string `json:"userID"`
Permissions []PermissionInput `json:"permissions"`
}
UserPermissionsInput