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

docs: remove non-usable workflow type in ami_imagebuilder_workflow resource #39864

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

stefanfreitag
Copy link
Contributor

@stefanfreitag stefanfreitag commented Oct 23, 2024

Description

The documentation of the resource ami_imagebuilder_workflow mentions for the argument type

Valid values: BUILD, TEST, DISTRIBUTION.

Image Builder handles the workflow type DISTRIBUTION, it cannot be configured by users. When trying to do so, for example using the code snippet provided as part of #39785

resource aws_imagebuilder_workflow codebuild-projects {
  name = "CodeBuildProjectsDistributionWorkflow"
  version = "1.0.0"
  type = "DISTRIBUTION"
  data = file("${path.module}/codebuild-projects-distribution.workflow.yaml")
}

the API returns the error The value supplied for parameter 'type' is not valid. Custom distribution workflows are not supported.

This pull request is to update the documentation for the resource. Jared Baker provided an idea for the required change:

Removing the DISTRIBUTION valid value from the docs, or explicitly stating it is only for internal Image Builder workflows provides guidance that it’s not usable. I

Relations

References

Here I explained the current situation.

Output from Acceptance Testing

Not required. Only documentation changed.

### Description

The documentation of the resource [`ami_imagebuilder_workflow`](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/imagebuilder_workflow)  mentions for the argument `type`
>  Valid values: BUILD, TEST, DISTRIBUTION.

Image Builder handles the  workflow type DISTRIBUTION, it cannot be configured by users.
When trying to do so, for example using the code snippet provided as part of hashicorp#39785 

```hcl
resource aws_imagebuilder_workflow codebuild-projects {
  name = "CodeBuildProjectsDistributionWorkflow"
  version = "1.0.0"
  type = "DISTRIBUTION"
  data = file("${path.module}/codebuild-projects-distribution.workflow.yaml")
}
```

the API returns the error ` The value supplied for parameter 'type' is not valid. Custom distribution workflows are not supported.`

This pull request is to update the documentation for the resource.

### Relations

Closes hashicorp#39785 

### References

[Here](hashicorp#39785 (comment)) I explained the current situation.

### Output from Acceptance Testing

Not required. Only documentation changed.
Copy link

Community Note

Voting for Prioritization

  • Please vote on this pull request by adding a 👍 reaction to the original post to help the community and maintainers prioritize this pull request.
  • Please see our prioritization guide for information on how we prioritize.
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.

For Submitters

  • Review the contribution guide relating to the type of change you are making to ensure all of the necessary steps have been taken.
  • For new resources and data sources, use skaff to generate scaffolding with comments detailing common expectations.
  • Whether or not the branch has been rebased will not impact prioritization, but doing so is always a welcome surprise.

@github-actions github-actions bot added documentation Introduces or discusses updates to documentation. service/imagebuilder Issues and PRs that pertain to the imagebuilder service. needs-triage Waiting for first response or review from a maintainer. labels Oct 23, 2024
@stefanfreitag stefanfreitag marked this pull request as ready for review October 23, 2024 20:35
@stefanfreitag stefanfreitag requested a review from a team as a code owner October 23, 2024 20:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Introduces or discusses updates to documentation. needs-triage Waiting for first response or review from a maintainer. service/imagebuilder Issues and PRs that pertain to the imagebuilder service.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: aws_imagebuilder_workflow allows invalid value "DISTRIBUTION" for 'type' argument
2 participants