Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Separate the provisionerd server into it's own package #4940

Merged
merged 6 commits into from
Nov 8, 2022

Conversation

kylecarbs
Copy link
Member

@kylecarbs kylecarbs commented Nov 7, 2022

This code should be thoroughly tested now that we understand the abstraction.

I separated it to make our lives a bit easier for external provisioner daemons as well!

  • Add a boatload of tests!

This code should be thoroughly tested now that we understand the abstraction.

I separated it to make our lives a bit easier for external provisioner daemons
as well!
@kylecarbs kylecarbs self-assigned this Nov 7, 2022
@kylecarbs kylecarbs marked this pull request as ready for review November 8, 2022 00:23
Comment on lines +914 to +932
// WorkspaceProvisionJob is the payload for the "workspace_provision" job type.
type WorkspaceProvisionJob struct {
WorkspaceBuildID uuid.UUID `json:"workspace_build_id"`
DryRun bool `json:"dry_run"`
}

// TemplateVersionDryRunJob is the payload for the "template_version_dry_run" job type.
type TemplateVersionDryRunJob struct {
TemplateVersionID uuid.UUID `json:"template_version_id"`
WorkspaceName string `json:"workspace_name"`
ParameterValues []database.ParameterValue `json:"parameter_values"`
}

// ProvisionerJobLogsNotifyMessage is the payload published on
// the provisioner job logs notify channel.
type ProvisionerJobLogsNotifyMessage struct {
CreatedAfter int64 `json:"created_after"`
EndOfLogs bool `json:"end_of_logs,omitempty"`
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

random nit; it feels weird that these are at the bottom

Copy link
Member Author

@kylecarbs kylecarbs Nov 8, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i had them at the top and it felt weird too... tbh they are weird structs

@kylecarbs kylecarbs enabled auto-merge (squash) November 8, 2022 00:45
@kylecarbs kylecarbs merged commit da05bbb into main Nov 8, 2022
@kylecarbs kylecarbs deleted the provisionerserver branch November 8, 2022 01:10
@github-actions github-actions bot locked and limited conversation to collaborators Nov 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants