mirror of
https://github.com/coder/coder.git
synced 2026-06-04 13:38:21 +00:00
feat(coderd): add has_external_agent flag to template_versions and workspace_builds (#19285)
This pull request introduces support for external workspace management, allowing users to register and manage workspaces that are provisioned and managed outside of the Coder. * Added has_external_agent field to workspace builds and template versions
This commit is contained in:
Generated
+5
-1
@@ -1691,7 +1691,8 @@ CREATE TABLE template_versions (
|
||||
message character varying(1048576) DEFAULT ''::character varying NOT NULL,
|
||||
archived boolean DEFAULT false NOT NULL,
|
||||
source_example_id text,
|
||||
has_ai_task boolean
|
||||
has_ai_task boolean,
|
||||
has_external_agent boolean
|
||||
);
|
||||
|
||||
COMMENT ON COLUMN template_versions.external_auth_providers IS 'IDs of External auth providers for a specific template version';
|
||||
@@ -1722,6 +1723,7 @@ CREATE VIEW template_version_with_user AS
|
||||
template_versions.archived,
|
||||
template_versions.source_example_id,
|
||||
template_versions.has_ai_task,
|
||||
template_versions.has_external_agent,
|
||||
COALESCE(visible_users.avatar_url, ''::text) AS created_by_avatar_url,
|
||||
COALESCE(visible_users.username, ''::text) AS created_by_username,
|
||||
COALESCE(visible_users.name, ''::text) AS created_by_name
|
||||
@@ -2264,6 +2266,7 @@ CREATE TABLE workspace_builds (
|
||||
template_version_preset_id uuid,
|
||||
has_ai_task boolean,
|
||||
ai_task_sidebar_app_id uuid,
|
||||
has_external_agent boolean,
|
||||
CONSTRAINT workspace_builds_ai_task_sidebar_app_id_required CHECK (((((has_ai_task IS NULL) OR (has_ai_task = false)) AND (ai_task_sidebar_app_id IS NULL)) OR ((has_ai_task = true) AND (ai_task_sidebar_app_id IS NOT NULL)))),
|
||||
CONSTRAINT workspace_builds_deadline_below_max_deadline CHECK ((((deadline <> '0001-01-01 00:00:00+00'::timestamp with time zone) AND (deadline <= max_deadline)) OR (max_deadline = '0001-01-01 00:00:00+00'::timestamp with time zone)))
|
||||
);
|
||||
@@ -2286,6 +2289,7 @@ CREATE VIEW workspace_build_with_user AS
|
||||
workspace_builds.template_version_preset_id,
|
||||
workspace_builds.has_ai_task,
|
||||
workspace_builds.ai_task_sidebar_app_id,
|
||||
workspace_builds.has_external_agent,
|
||||
COALESCE(visible_users.avatar_url, ''::text) AS initiator_by_avatar_url,
|
||||
COALESCE(visible_users.username, ''::text) AS initiator_by_username,
|
||||
COALESCE(visible_users.name, ''::text) AS initiator_by_name
|
||||
|
||||
Reference in New Issue
Block a user