Skip to content

Commit

Permalink
Regenerate workflows with taxonomies
Browse files Browse the repository at this point in the history
  • Loading branch information
Nishu Goel committed Nov 15, 2024
1 parent f8b7312 commit 83e9278
Show file tree
Hide file tree
Showing 145 changed files with 6,877 additions and 1,713 deletions.
314 changes: 235 additions & 79 deletions .speakeasy/gen.lock

Large diffs are not rendered by default.

17 changes: 15 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,8 +1,21 @@
.PHONY: all docs
all: docs speakeasy
all: speakeasy docs

original.yaml:
cp workflow.yaml original.yaml

original_modified.yaml: original.yaml overlay.yaml
speakeasy overlay apply -s original.yaml -o overlay.yaml > original_modified.yaml

overlay.yaml:
speakeasy overlay compare -s original.yaml -s original_modified.yaml > overlay.yaml

speakeasy:
speakeasy generate sdk --lang terraform -o . -s workflow.yaml
$(eval TMP := $(shell mktemp -d))
# curl https://docs.api.epilot.io/workflows-definition.yaml > $(TMP)/openapi.yaml
cp workflow.yaml $(TMP)/openapi.yaml
speakeasy overlay apply -s $(TMP)/openapi.yaml -o overlay.yaml > $(TMP)/final.yaml
speakeasy generate sdk --lang terraform -o . -s $(TMP)/final.yaml

docs:
go generate ./...
Expand Down
68 changes: 55 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ TF_REATTACH_PROVIDERS=... terraform apply

<!-- End SDK <no value> -->

<!-- Start SDK Installation [installation] -->
## SDK Installation
<!-- Start Installation [installation] -->
## Installation

To install this provider, copy and paste this code into your Terraform configuration. Then, run `terraform init`.

Expand All @@ -61,7 +61,7 @@ terraform {
required_providers {
epilot-workflow = {
source = "epilot-dev/epilot-workflow"
version = "0.13.0"
version = "0.15.2"
}
}
}
Expand All @@ -70,19 +70,17 @@ provider "epilot-workflow" {
# Configuration options
}
```
<!-- End SDK Installation [installation] -->
<!-- End Installation [installation] -->

<!-- Start SDK Example Usage [usage] -->
## SDK Example Usage
<!-- Start Testing the provider locally [usage] -->
## Testing the provider locally

### Testing the provider locally
#### Local Provider

Should you want to validate a change locally, the `--debug` flag allows you to execute the provider against a terraform instance locally.

This also allows for debuggers (e.g. delve) to be attached to the provider.

### Example

```sh
go run main.go --debug
# Copy the TF_REATTACH_PROVIDERS env var
Expand All @@ -91,13 +89,57 @@ cd examples/your-example
TF_REATTACH_PROVIDERS=... terraform init
TF_REATTACH_PROVIDERS=... terraform apply
```
<!-- End SDK Example Usage [usage] -->

<!-- Start Available Resources and Operations [operations] -->
## Available Resources and Operations
#### Compiled Provider

Terraform allows you to use local provider builds by setting a `dev_overrides` block in a configuration file called `.terraformrc`. This block overrides all other configured installation methods.

1. Execute `go build` to construct a binary called `terraform-provider-epilot-workflow`
2. Ensure that the `.terraformrc` file is configured with a `dev_overrides` section such that your local copy of terraform can see the provider binary

Terraform searches for the `.terraformrc` file in your home directory and applies any configuration settings you set.

```
provider_installation {
dev_overrides {
"registry.terraform.io/epilot-dev/epilot-workflow" = "<PATH>"
}
# For all other providers, install them directly from their origin provider
# registries as normal. If you omit this, Terraform will _only_ use
# the dev_overrides block, and so no other providers will be available.
direct {}
}
```
<!-- End Testing the provider locally [usage] -->

<!-- Start Available Resources and Data Sources [operations] -->
## Available Resources and Data Sources

### Resources

* [epilot-workflow_closing_reason](docs/resources/closing_reason.md)
* [epilot-workflow_workflow_definition](docs/resources/workflow_definition.md)
### Data Sources

* [epilot-workflow_closing_reason](docs/data-sources/closing_reason.md)
* [epilot-workflow_workflow_definition](docs/data-sources/workflow_definition.md)
<!-- End Available Resources and Data Sources [operations] -->

<!-- Start Summary [summary] -->
## Summary

Workflows Definitions: Service for Workflow Definitions for different processes inside of an Organization
<!-- End Summary [summary] -->

<!-- Start Table of Contents [toc] -->
## Table of Contents

<!-- End Available Resources and Operations [operations] -->
* [Installation](#installation)
* [Available Resources and Data Sources](#available-resources-and-data-sources)
* [Testing the provider locally](#testing-the-provider-locally)
<!-- End Table of Contents [toc] -->

<!-- Placeholder for Future Speakeasy SDK Sections -->

Expand Down
5 changes: 1 addition & 4 deletions docs/data-sources/closing_reason.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ ClosingReason DataSource

```terraform
data "epilot-workflow_closing_reason" "my_closingreason" {
reason_id = "-poOAPBa-jFZA_AWV3zN0"
}
```

Expand All @@ -26,7 +25,5 @@ data "epilot-workflow_closing_reason" "my_closingreason" {
- `creation_time` (String)
- `id` (String) The ID of this resource.
- `last_update_time` (String)
- `status` (String) must be one of ["ACTIVE", "INACTIVE"]
- `status` (String)
- `title` (String)


Loading

0 comments on commit 83e9278

Please sign in to comment.