PrefectHQ / terraform-provider-prefect

Terraform Provider for Prefect Cloud
https://registry.terraform.io/providers/PrefectHQ/prefect/latest/docs
Apache License 2.0
29 stars 13 forks source link

feat(deployment): add Deployment resource #202

Open skyscrapr opened 3 weeks ago

skyscrapr commented 3 weeks ago

Adds Deployment resource.

Depends on https://github.com/PrefectHQ/terraform-provider-prefect/pull/201.

Running tool: /opt/homebrew/bin/go test -timeout 30s -run ^TestAccResource_deployment$ github.com/prefecthq/terraform-provider-prefect/internal/provider/resources

ok      github.com/prefecthq/terraform-provider-prefect/internal/provider/resources 6.103s
mitchnielsen commented 2 weeks ago

Thanks for the contribution @skyscrapr 🤝

Now that you've opened https://github.com/PrefectHQ/terraform-provider-prefect/pull/201, could you please remove the Flow-related code to keep this PR focused on Deployments?

skyscrapr commented 2 weeks ago

Deployments are dependent on flows You cannot create a deployment without a flow_id.

I split flows into #201. But I'm unsure. How to create this PR if it requires another PR to be merged first. The branch will not pass tests.

If you explain how to do this, happy to update the PR and remove flows.

I have a third PR for deployment access that I haven't opened since it is depending on deployments and only makes the problem worse.

skyscrapr commented 2 weeks ago

The other option is to merge #201 and that should remove flows from #202 automatically.

mitchnielsen commented 2 weeks ago

Yeah, I was thinking we could set the Deployment PR's branch target to this Flow PR, but I don't think there's a way to do that with forks.

Let's mark the Deployment PR as draft for now, and when this PR merges we'll revisit that one. That way, any changes we make here don't need to also be applied to your Deployment PR.