Skip to content

Commit 2be2d90

Browse files
author
Nishu Goel
committed
Update provider to add workflow.lock
1 parent d491198 commit 2be2d90

File tree

117 files changed

+4199
-2357
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

117 files changed

+4199
-2357
lines changed

.github/workflows/autorelease.yml

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
name: Autorelease
2+
3+
# On each main branch push, bump version and publish a release
4+
"on":
5+
push:
6+
branches:
7+
- main
8+
9+
# Releases need permissions to read and write the repository contents.
10+
# GitHub considers creating releases and uploading assets as writing contents.
11+
permissions:
12+
contents: write
13+
14+
jobs:
15+
autorelease:
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
# Semver
21+
- name: Get Next Version
22+
id: semver
23+
uses: ietf-tools/semver-action@v1
24+
with:
25+
token: ${{ secrets.GITHUB_TOKEN }}
26+
branch: main
27+
skipInvalidTags: true
28+
patchList: ci,fix,bugfix,perf,refactor,test,tests
29+
- name: Create Release
30+
uses: ncipollo/[email protected]
31+
with:
32+
allowUpdates: true
33+
draft: false
34+
makeLatest: true
35+
name: ${{ steps.semver.outputs.next }}
36+
tag: ${{ steps.semver.outputs.next }}
37+
body: Update Terraform Provider with latest API changes
38+
token: ${{ secrets.GITHUB_TOKEN }}
39+
40+
41+
# Re-run checkout to load the updated release tag
42+
- uses: actions/checkout@v4
43+
with:
44+
fetch-depth: 0
45+
46+
# Goreleaser
47+
- uses: actions/setup-go@4d34df0c2316fe8122ab82dc22947d607c0c91f9 # v4.0.0
48+
with:
49+
go-version-file: 'go.mod'
50+
cache: true
51+
- name: Import GPG key
52+
uses: crazy-max/ghaction-import-gpg@111c56156bcc6918c056dbef52164cfa583dc549 # v5.2.0
53+
id: import_gpg
54+
with:
55+
gpg_private_key: ${{ secrets.TERRAFORM_GPG_PRIVATE_KEY }}
56+
passphrase: ${{ secrets.TERRAFORM_GPG_PASSPHRASE }}
57+
- name: Run GoReleaser
58+
uses: goreleaser/goreleaser-action@f82d6c1c344bcacabba2c841718984797f664a6b # v4.2.0
59+
with:
60+
args: release --clean
61+
env:
62+
# GitHub sets the GITHUB_TOKEN secret automatically.
63+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
64+
GPG_FINGERPRINT: ${{ steps.import_gpg.outputs.fingerprint }}
65+
66+
# Trigger gitlab pipeline
67+
- name: Trigger gitlab pipeline
68+
uses: appleboy/[email protected]
69+
with:
70+
host: "https://gitlab.com"
71+
token: ${{ secrets.GITLAB_PROVIDERS_TOKEN }}
72+
project_id: 54648643
73+
ref: providers
74+

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
**/.speakeasy/temp/
2+
**/.speakeasy/logs/
13
.terraform
24
.terraform*
35
*.tfstate*

.speakeasy/gen.lock

Lines changed: 121 additions & 81 deletions
Large diffs are not rendered by default.

.speakeasy/workflow.lock

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
speakeasyVersion: 1.606.10
2+
sources:
3+
my-source:
4+
sourceNamespace: my-source
5+
sourceRevisionDigest: sha256:2ee81d075cfd43eeb48662bce1ecc240dd0dd642c3f5a17946ecdd6902fea272
6+
sourceBlobDigest: sha256:ca57c9f570036cc2e6be6bc717859bdf514add526b696920bca75f1801c7cace
7+
tags:
8+
- latest
9+
- 1.0.0
10+
targets:
11+
terraform:
12+
source: my-source
13+
sourceNamespace: my-source
14+
sourceRevisionDigest: sha256:2ee81d075cfd43eeb48662bce1ecc240dd0dd642c3f5a17946ecdd6902fea272
15+
sourceBlobDigest: sha256:ca57c9f570036cc2e6be6bc717859bdf514add526b696920bca75f1801c7cace
16+
workflow:
17+
workflowVersion: 1.0.0
18+
speakeasyVersion: latest
19+
sources:
20+
my-source:
21+
inputs:
22+
- location: https://docs.api.epilot.io/workflows-definition.yaml
23+
output: final.yaml
24+
registry:
25+
location: registry.speakeasyapi.dev/epilot/epilot/my-source
26+
targets:
27+
terraform:
28+
target: terraform
29+
source: my-source

.speakeasy/workflow.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
11
workflowVersion: 1.0.0
2+
speakeasyVersion: latest
23
sources:
34
my-source:
45
inputs:
56
- location: https://docs.api.epilot.io/workflows-definition.yaml
7+
output: final.yaml
8+
registry:
9+
location: registry.speakeasyapi.dev/epilot/epilot/my-source
610
targets:
711
terraform:
812
target: terraform

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
all: speakeasy docs
33

44
original.yaml:
5-
cp workflow.yaml original.yaml
5+
cp workflows.yaml original.yaml
66

77
original_modified.yaml: original.yaml overlay.yaml
88
speakeasy overlay apply -s original.yaml -o overlay.yaml > original_modified.yaml
@@ -13,7 +13,7 @@ overlay.yaml:
1313
speakeasy:
1414
$(eval TMP := $(shell mktemp -d))
1515
# curl https://docs.api.epilot.io/workflows-definition.yaml > $(TMP)/openapi.yaml
16-
cp workflow.yaml $(TMP)/openapi.yaml
16+
cp workflows.yaml $(TMP)/openapi.yaml
1717
speakeasy overlay apply -s $(TMP)/openapi.yaml -o overlay.yaml > $(TMP)/final.yaml
1818
speakeasy generate sdk --lang terraform -o . -s $(TMP)/final.yaml
1919

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ terraform {
6161
required_providers {
6262
epilot-workflow = {
6363
source = "epilot-dev/epilot-workflow"
64-
version = "0.17.0"
64+
version = "0.19.0"
6565
}
6666
}
6767
}

docs/data-sources/workflow_definition.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ data "epilot-workflow_workflow_definition" "my_workflowdefinition" {
3636
- `name` (String)
3737
- `taxonomies` (List of String) Taxonomy ids that are associated with this workflow and used for filtering
3838
- `update_entity_attributes` (Attributes List) (see [below for nested schema](#nestedatt--update_entity_attributes))
39-
- `user_ids` (List of Number) This field is deprecated. Please use assignedTo
39+
- `user_ids` (List of Number, Deprecated) This field is deprecated. Please use assignedTo
4040

4141
<a id="nestedatt--closing_reasons"></a>
4242
### Nested Schema for `closing_reasons`

docs/index.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
---
22
# generated by https://github.com/hashicorp/terraform-plugin-docs
33
page_title: "epilot-workflow Provider"
4-
subcategory: ""
54
description: |-
65
Workflows Definitions: Service for Workflow Definitions for different processes inside of an Organization
76
---
@@ -17,7 +16,7 @@ terraform {
1716
required_providers {
1817
epilot-workflow = {
1918
source = "epilot-dev/epilot-workflow"
20-
version = "0.17.0"
19+
version = "0.19.0"
2120
}
2221
}
2322
}
@@ -30,7 +29,10 @@ provider "epilot-workflow" {
3029
<!-- schema generated by tfplugindocs -->
3130
## Schema
3231

33-
### Optional
32+
### Required
3433

3534
- `bearer_auth` (String, Sensitive)
35+
36+
### Optional
37+
3638
- `server_url` (String) Server URL (defaults to https://workflows-definition.sls.epilot.io)

docs/resources/closing_reason.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,17 @@ resource "epilot-workflow_closing_reason" "my_closingreason" {
3737

3838
Import is supported using the following syntax:
3939

40+
In Terraform v1.5.0 and later, the [`import` block](https://developer.hashicorp.com/terraform/language/import) can be used with the `id` attribute, for example:
41+
42+
```terraform
43+
import {
44+
to = epilot-workflow_closing_reason.my_epilot-workflow_closing_reason
45+
id = "..."
46+
}
47+
```
48+
49+
The [`terraform import` command](https://developer.hashicorp.com/terraform/cli/commands/import) can be used, for example:
50+
4051
```shell
41-
terraform import epilot-workflow_closing_reason.my_epilot-workflow_closing_reason ""
52+
terraform import epilot-workflow_closing_reason.my_epilot-workflow_closing_reason "..."
4253
```

0 commit comments

Comments
 (0)