Documentation
¶
Index ¶
- Constants
- type APIError
- type Application
- type Client
- func (c *Client) ControlApplication(uuid string, op LifecycleOperation) (*LifecycleResponse, error)
- func (c *Client) ControlService(uuid string, op LifecycleOperation) (*LifecycleResponse, error)
- func (c *Client) Deploy(applicationUUID string, force bool) (*DeployResponse, error)
- func (c *Client) ListApplications() ([]Application, error)
- func (c *Client) ListServices() ([]Service, error)
- func (c *Client) Verify() error
- type Configuration
- type ControlApplication
- func (c *ControlApplication) Cancel(ctx core.ExecutionContext) error
- func (c *ControlApplication) Cleanup(ctx core.SetupContext) error
- func (c *ControlApplication) Color() string
- func (c *ControlApplication) Configuration() []configuration.Field
- func (c *ControlApplication) Description() string
- func (c *ControlApplication) Documentation() string
- func (c *ControlApplication) ExampleOutput() map[string]any
- func (c *ControlApplication) Execute(ctx core.ExecutionContext) error
- func (c *ControlApplication) HandleHook(ctx core.ActionHookContext) error
- func (c *ControlApplication) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (c *ControlApplication) Hooks() []core.Hook
- func (c *ControlApplication) Icon() string
- func (c *ControlApplication) Label() string
- func (c *ControlApplication) Name() string
- func (c *ControlApplication) OutputChannels(configuration any) []core.OutputChannel
- func (c *ControlApplication) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (c *ControlApplication) Setup(ctx core.SetupContext) error
- type ControlApplicationSpec
- type ControlService
- func (c *ControlService) Cancel(ctx core.ExecutionContext) error
- func (c *ControlService) Cleanup(ctx core.SetupContext) error
- func (c *ControlService) Color() string
- func (c *ControlService) Configuration() []configuration.Field
- func (c *ControlService) Description() string
- func (c *ControlService) Documentation() string
- func (c *ControlService) ExampleOutput() map[string]any
- func (c *ControlService) Execute(ctx core.ExecutionContext) error
- func (c *ControlService) HandleHook(ctx core.ActionHookContext) error
- func (c *ControlService) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (c *ControlService) Hooks() []core.Hook
- func (c *ControlService) Icon() string
- func (c *ControlService) Label() string
- func (c *ControlService) Name() string
- func (c *ControlService) OutputChannels(configuration any) []core.OutputChannel
- func (c *ControlService) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (c *ControlService) Setup(ctx core.SetupContext) error
- type ControlServiceSpec
- type Coolify
- func (c *Coolify) Actions() []core.Action
- func (c *Coolify) Cleanup(ctx core.IntegrationCleanupContext) error
- func (c *Coolify) Configuration() []configuration.Field
- func (c *Coolify) Description() string
- func (c *Coolify) HandleHook(ctx core.IntegrationHookContext) error
- func (c *Coolify) HandleRequest(ctx core.HTTPRequestContext)
- func (c *Coolify) Hooks() []core.Hook
- func (c *Coolify) Icon() string
- func (c *Coolify) Instructions() string
- func (c *Coolify) Label() string
- func (c *Coolify) ListResources(resourceType string, ctx core.ListResourcesContext) ([]core.IntegrationResource, error)
- func (c *Coolify) Name() string
- func (c *Coolify) Sync(ctx core.SyncContext) error
- func (c *Coolify) Triggers() []core.Trigger
- type DeployApplication
- func (c *DeployApplication) Cancel(ctx core.ExecutionContext) error
- func (c *DeployApplication) Cleanup(ctx core.SetupContext) error
- func (c *DeployApplication) Color() string
- func (c *DeployApplication) Configuration() []configuration.Field
- func (c *DeployApplication) Description() string
- func (c *DeployApplication) Documentation() string
- func (c *DeployApplication) ExampleOutput() map[string]any
- func (c *DeployApplication) Execute(ctx core.ExecutionContext) error
- func (c *DeployApplication) HandleHook(ctx core.ActionHookContext) error
- func (c *DeployApplication) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (c *DeployApplication) Hooks() []core.Hook
- func (c *DeployApplication) Icon() string
- func (c *DeployApplication) Label() string
- func (c *DeployApplication) Name() string
- func (c *DeployApplication) OutputChannels(configuration any) []core.OutputChannel
- func (c *DeployApplication) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (c *DeployApplication) Setup(ctx core.SetupContext) error
- type DeployApplicationSpec
- type DeployResponse
- type Deployment
- type LifecycleOperation
- type LifecycleResponse
- type ListApplications
- func (c *ListApplications) Cancel(ctx core.ExecutionContext) error
- func (c *ListApplications) Cleanup(ctx core.SetupContext) error
- func (c *ListApplications) Color() string
- func (c *ListApplications) Configuration() []configuration.Field
- func (c *ListApplications) Description() string
- func (c *ListApplications) Documentation() string
- func (c *ListApplications) ExampleOutput() map[string]any
- func (c *ListApplications) Execute(ctx core.ExecutionContext) error
- func (c *ListApplications) HandleHook(ctx core.ActionHookContext) error
- func (c *ListApplications) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (c *ListApplications) Hooks() []core.Hook
- func (c *ListApplications) Icon() string
- func (c *ListApplications) Label() string
- func (c *ListApplications) Name() string
- func (c *ListApplications) OutputChannels(configuration any) []core.OutputChannel
- func (c *ListApplications) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (c *ListApplications) Setup(ctx core.SetupContext) error
- type ListServices
- func (c *ListServices) Cancel(ctx core.ExecutionContext) error
- func (c *ListServices) Cleanup(ctx core.SetupContext) error
- func (c *ListServices) Color() string
- func (c *ListServices) Configuration() []configuration.Field
- func (c *ListServices) Description() string
- func (c *ListServices) Documentation() string
- func (c *ListServices) ExampleOutput() map[string]any
- func (c *ListServices) Execute(ctx core.ExecutionContext) error
- func (c *ListServices) HandleHook(ctx core.ActionHookContext) error
- func (c *ListServices) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (c *ListServices) Hooks() []core.Hook
- func (c *ListServices) Icon() string
- func (c *ListServices) Label() string
- func (c *ListServices) Name() string
- func (c *ListServices) OutputChannels(configuration any) []core.OutputChannel
- func (c *ListServices) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (c *ListServices) Setup(ctx core.SetupContext) error
- type Service
Constants ¶
const ControlApplicationPayloadType = "coolify.application.controlled"
const ControlServicePayloadType = "coolify.service.controlled"
const DeployApplicationPayloadType = "coolify.application.deploy.queued"
const ListApplicationsPayloadType = "coolify.applications.listed"
const ListServicesPayloadType = "coolify.services.listed"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Application ¶
type Application struct {
UUID string `json:"uuid"`
Name string `json:"name"`
Status string `json:"status"`
FQDN string `json:"fqdn"`
Description string `json:"description"`
GitRepo string `json:"git_repository"`
GitBranch string `json:"git_branch"`
}
Application represents the fields the connector cares about from the Coolify applications API.
type Client ¶
func NewClient ¶
func NewClient(httpCtx core.HTTPContext, integration core.IntegrationContext) (*Client, error)
func (*Client) ControlApplication ¶
func (c *Client) ControlApplication(uuid string, op LifecycleOperation) (*LifecycleResponse, error)
func (*Client) ControlService ¶
func (c *Client) ControlService(uuid string, op LifecycleOperation) (*LifecycleResponse, error)
func (*Client) Deploy ¶
func (c *Client) Deploy(applicationUUID string, force bool) (*DeployResponse, error)
Deploy queues a deployment for the given application UUID. force=true triggers a fresh build instead of redeploying the existing image.
func (*Client) ListApplications ¶
func (c *Client) ListApplications() ([]Application, error)
func (*Client) ListServices ¶
type Configuration ¶
type ControlApplication ¶
type ControlApplication struct{}
func (*ControlApplication) Cancel ¶
func (c *ControlApplication) Cancel(ctx core.ExecutionContext) error
func (*ControlApplication) Cleanup ¶
func (c *ControlApplication) Cleanup(ctx core.SetupContext) error
func (*ControlApplication) Color ¶
func (c *ControlApplication) Color() string
func (*ControlApplication) Configuration ¶
func (c *ControlApplication) Configuration() []configuration.Field
func (*ControlApplication) Description ¶
func (c *ControlApplication) Description() string
func (*ControlApplication) Documentation ¶
func (c *ControlApplication) Documentation() string
func (*ControlApplication) ExampleOutput ¶
func (c *ControlApplication) ExampleOutput() map[string]any
func (*ControlApplication) Execute ¶
func (c *ControlApplication) Execute(ctx core.ExecutionContext) error
func (*ControlApplication) HandleHook ¶
func (c *ControlApplication) HandleHook(ctx core.ActionHookContext) error
func (*ControlApplication) HandleWebhook ¶
func (c *ControlApplication) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*ControlApplication) Hooks ¶
func (c *ControlApplication) Hooks() []core.Hook
func (*ControlApplication) Icon ¶
func (c *ControlApplication) Icon() string
func (*ControlApplication) Label ¶
func (c *ControlApplication) Label() string
func (*ControlApplication) Name ¶
func (c *ControlApplication) Name() string
func (*ControlApplication) OutputChannels ¶
func (c *ControlApplication) OutputChannels(configuration any) []core.OutputChannel
func (*ControlApplication) ProcessQueueItem ¶
func (c *ControlApplication) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
func (*ControlApplication) Setup ¶
func (c *ControlApplication) Setup(ctx core.SetupContext) error
type ControlApplicationSpec ¶
type ControlService ¶
type ControlService struct{}
func (*ControlService) Cancel ¶
func (c *ControlService) Cancel(ctx core.ExecutionContext) error
func (*ControlService) Cleanup ¶
func (c *ControlService) Cleanup(ctx core.SetupContext) error
func (*ControlService) Color ¶
func (c *ControlService) Color() string
func (*ControlService) Configuration ¶
func (c *ControlService) Configuration() []configuration.Field
func (*ControlService) Description ¶
func (c *ControlService) Description() string
func (*ControlService) Documentation ¶
func (c *ControlService) Documentation() string
func (*ControlService) ExampleOutput ¶
func (c *ControlService) ExampleOutput() map[string]any
func (*ControlService) Execute ¶
func (c *ControlService) Execute(ctx core.ExecutionContext) error
func (*ControlService) HandleHook ¶
func (c *ControlService) HandleHook(ctx core.ActionHookContext) error
func (*ControlService) HandleWebhook ¶
func (c *ControlService) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*ControlService) Hooks ¶
func (c *ControlService) Hooks() []core.Hook
func (*ControlService) Icon ¶
func (c *ControlService) Icon() string
func (*ControlService) Label ¶
func (c *ControlService) Label() string
func (*ControlService) Name ¶
func (c *ControlService) Name() string
func (*ControlService) OutputChannels ¶
func (c *ControlService) OutputChannels(configuration any) []core.OutputChannel
func (*ControlService) ProcessQueueItem ¶
func (c *ControlService) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
func (*ControlService) Setup ¶
func (c *ControlService) Setup(ctx core.SetupContext) error
type ControlServiceSpec ¶
type Coolify ¶
type Coolify struct{}
func (*Coolify) Configuration ¶
func (c *Coolify) Configuration() []configuration.Field
func (*Coolify) Description ¶
func (*Coolify) HandleHook ¶
func (c *Coolify) HandleHook(ctx core.IntegrationHookContext) error
func (*Coolify) HandleRequest ¶
func (c *Coolify) HandleRequest(ctx core.HTTPRequestContext)
func (*Coolify) Instructions ¶
func (*Coolify) ListResources ¶
func (c *Coolify) ListResources(resourceType string, ctx core.ListResourcesContext) ([]core.IntegrationResource, error)
type DeployApplication ¶
type DeployApplication struct{}
func (*DeployApplication) Cancel ¶
func (c *DeployApplication) Cancel(ctx core.ExecutionContext) error
func (*DeployApplication) Cleanup ¶
func (c *DeployApplication) Cleanup(ctx core.SetupContext) error
func (*DeployApplication) Color ¶
func (c *DeployApplication) Color() string
func (*DeployApplication) Configuration ¶
func (c *DeployApplication) Configuration() []configuration.Field
func (*DeployApplication) Description ¶
func (c *DeployApplication) Description() string
func (*DeployApplication) Documentation ¶
func (c *DeployApplication) Documentation() string
func (*DeployApplication) ExampleOutput ¶
func (c *DeployApplication) ExampleOutput() map[string]any
func (*DeployApplication) Execute ¶
func (c *DeployApplication) Execute(ctx core.ExecutionContext) error
func (*DeployApplication) HandleHook ¶
func (c *DeployApplication) HandleHook(ctx core.ActionHookContext) error
func (*DeployApplication) HandleWebhook ¶
func (c *DeployApplication) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*DeployApplication) Hooks ¶
func (c *DeployApplication) Hooks() []core.Hook
func (*DeployApplication) Icon ¶
func (c *DeployApplication) Icon() string
func (*DeployApplication) Label ¶
func (c *DeployApplication) Label() string
func (*DeployApplication) Name ¶
func (c *DeployApplication) Name() string
func (*DeployApplication) OutputChannels ¶
func (c *DeployApplication) OutputChannels(configuration any) []core.OutputChannel
func (*DeployApplication) ProcessQueueItem ¶
func (c *DeployApplication) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
func (*DeployApplication) Setup ¶
func (c *DeployApplication) Setup(ctx core.SetupContext) error
type DeployApplicationSpec ¶
type DeployResponse ¶
type DeployResponse struct {
Deployments []Deployment `json:"deployments"`
Message string `json:"message"`
}
DeployResponse is the body returned by GET /api/v1/deploy. It contains the queued deployment(s); we expose the first one.
type Deployment ¶
type LifecycleOperation ¶
type LifecycleOperation string
LifecycleOperation is the operation requested on a Coolify resource.
const ( LifecycleStart LifecycleOperation = "start" LifecycleStop LifecycleOperation = "stop" LifecycleRestart LifecycleOperation = "restart" )
func (LifecycleOperation) IsValid ¶
func (op LifecycleOperation) IsValid() bool
IsValid returns true when op is one of the known lifecycle operations.
type LifecycleResponse ¶
type LifecycleResponse struct {
Message string `json:"message"`
}
LifecycleResponse is the body returned by start/stop/restart endpoints. Coolify returns a small JSON object with a confirmation message.
type ListApplications ¶
type ListApplications struct{}
func (*ListApplications) Cancel ¶
func (c *ListApplications) Cancel(ctx core.ExecutionContext) error
func (*ListApplications) Cleanup ¶
func (c *ListApplications) Cleanup(ctx core.SetupContext) error
func (*ListApplications) Color ¶
func (c *ListApplications) Color() string
func (*ListApplications) Configuration ¶
func (c *ListApplications) Configuration() []configuration.Field
func (*ListApplications) Description ¶
func (c *ListApplications) Description() string
func (*ListApplications) Documentation ¶
func (c *ListApplications) Documentation() string
func (*ListApplications) ExampleOutput ¶
func (c *ListApplications) ExampleOutput() map[string]any
func (*ListApplications) Execute ¶
func (c *ListApplications) Execute(ctx core.ExecutionContext) error
func (*ListApplications) HandleHook ¶
func (c *ListApplications) HandleHook(ctx core.ActionHookContext) error
func (*ListApplications) HandleWebhook ¶
func (c *ListApplications) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*ListApplications) Hooks ¶
func (c *ListApplications) Hooks() []core.Hook
func (*ListApplications) Icon ¶
func (c *ListApplications) Icon() string
func (*ListApplications) Label ¶
func (c *ListApplications) Label() string
func (*ListApplications) Name ¶
func (c *ListApplications) Name() string
func (*ListApplications) OutputChannels ¶
func (c *ListApplications) OutputChannels(configuration any) []core.OutputChannel
func (*ListApplications) ProcessQueueItem ¶
func (c *ListApplications) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
func (*ListApplications) Setup ¶
func (c *ListApplications) Setup(ctx core.SetupContext) error
type ListServices ¶
type ListServices struct{}
func (*ListServices) Cancel ¶
func (c *ListServices) Cancel(ctx core.ExecutionContext) error
func (*ListServices) Cleanup ¶
func (c *ListServices) Cleanup(ctx core.SetupContext) error
func (*ListServices) Color ¶
func (c *ListServices) Color() string
func (*ListServices) Configuration ¶
func (c *ListServices) Configuration() []configuration.Field
func (*ListServices) Description ¶
func (c *ListServices) Description() string
func (*ListServices) Documentation ¶
func (c *ListServices) Documentation() string
func (*ListServices) ExampleOutput ¶
func (c *ListServices) ExampleOutput() map[string]any
func (*ListServices) Execute ¶
func (c *ListServices) Execute(ctx core.ExecutionContext) error
func (*ListServices) HandleHook ¶
func (c *ListServices) HandleHook(ctx core.ActionHookContext) error
func (*ListServices) HandleWebhook ¶
func (c *ListServices) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*ListServices) Hooks ¶
func (c *ListServices) Hooks() []core.Hook
func (*ListServices) Icon ¶
func (c *ListServices) Icon() string
func (*ListServices) Label ¶
func (c *ListServices) Label() string
func (*ListServices) Name ¶
func (c *ListServices) Name() string
func (*ListServices) OutputChannels ¶
func (c *ListServices) OutputChannels(configuration any) []core.OutputChannel
func (*ListServices) ProcessQueueItem ¶
func (c *ListServices) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
func (*ListServices) Setup ¶
func (c *ListServices) Setup(ctx core.SetupContext) error
type Service ¶
type Service struct {
UUID string `json:"uuid"`
Name string `json:"name"`
Status string `json:"status"`
FQDN string `json:"fqdn"`
Description string `json:"description"`
ServerUUID string `json:"server_uuid"`
}
Service represents the fields the connector cares about from the Coolify services API.