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

aws_workspace: Timeout reached on creation #13598

Closed
ghost opened this issue Jun 3, 2020 · 8 comments
Closed

aws_workspace: Timeout reached on creation #13598

ghost opened this issue Jun 3, 2020 · 8 comments
Labels
bug Addresses a defect in current functionality. service/workspaces Issues and PRs that pertain to the workspaces service.

Comments

@ghost
Copy link

ghost commented Jun 3, 2020

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • 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
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform Version

Terraform v0.12.24

Affected Resource(s)

  • aws_workspace

Terraform Configuration Files

# Copy-paste your Terraform configurations here - for large Terraform configs,
# please use a service like Dropbox and share a link to the ZIP file. For
# security, you can also encrypt the files using our GPG public key: https://keybase.io/hashicorp

resource "aws_workspaces_workspace" "workspace_racker" {
directory_id = module.directory.directory_id
bundle_id = data.aws_workspaces_bundle.standard_windows_10.id
user_name = "racker-test"

workspace_properties {
compute_type_name = data.aws_workspaces_bundle.standard_windows_10.compute_type[0].name
user_volume_size_gib = data.aws_workspaces_bundle.standard_windows_10.user_storage[0].capacity
root_volume_size_gib = data.aws_workspaces_bundle.standard_windows_10.root_storage[0].capacity
running_mode = "AUTO_STOP"
running_mode_auto_stop_timeout_in_minutes = 60
}

tags = {
Environment = "Development"
}

}

Debug Output

aws_workspaces_workspace.workspace_racker: Still creating... [29m1s elapsed]
aws_workspaces_workspace.workspace_racker: Still creating... [29m11s elapsed]
aws_workspaces_workspace.workspace_racker: Still creating... [29m21s elapsed]
aws_workspaces_workspace.workspace_racker: Still creating... [29m31s elapsed]
aws_workspaces_workspace.workspace_racker: Still creating... [29m41s elapsed]
aws_workspaces_workspace.workspace_racker: Still creating... [29m51s elapsed]
aws_workspaces_workspace.workspace_racker: Still creating... [30m1s elapsed]

Error: workspace "ws-7dq7plqrv" is not available: timeout while waiting for state to become 'AVAILABLE' (last state: 'PENDING', timeout: 30m0s)

on main.tf line 134, in resource "aws_workspaces_workspace" "workspace_racker":
134: resource "aws_workspaces_workspace" "workspace_racker" {

Panic Output

Expected Behavior

Workspace creation should be successful

Actual Behavior

Workspace creation reaches a timeout and the state is not updated successfully. Either the internal timeout should be updated or the nested block timeouts should be allowed, just like RDS

Steps to Reproduce

  1. terraform apply

Important Factoids

References

  • #0000
@ghost ghost added the service/workspaces Issues and PRs that pertain to the workspaces service. label Jun 3, 2020
@github-actions github-actions bot added the needs-triage Waiting for first response or review from a maintainer. label Jun 3, 2020
@fweep
Copy link

fweep commented Aug 21, 2020

This is a critical usability change. In us-east-1, there's about a 50-50 chance that a Workspace create will timeout. It's unusable for automation in its current state. Successful deploys take at least 20 minutes, and often skirt the edge of 30 minutes and just squeeze under. I don't know if other regions are faster, but this simply cannot be used for automated deploys in us-east-1 in its current state.

@bflad bflad added bug Addresses a defect in current functionality. and removed needs-triage Waiting for first response or review from a maintainer. labels Aug 21, 2020
@bflad
Copy link
Contributor

bflad commented Aug 21, 2020

Since this seems valid that the default timeout is too low. If anyone here would like to adjust this, it can be done by updating WorkspaceAvailableTimeout in aws/internal/service/workspaces/waiter/waiter.go to say, 60 minutes (unless the AWS service documentation provides better guidance on how long this can take).

@fweep
Copy link

fweep commented Aug 22, 2020

It would be better if it could be configured. Really, all resources should support adjustable timeouts, the way e.g. aws_db_instance does. Many resources in AWS take over 20 minutes to create at times, particularly Windows resources. I've been struggling with timeouts on aws_db_instance, aws_workspaces_workspace, aws_directory_service_directory, and others. AWS Microsoft Managed AD is particularly long-running, and multi-AZ SQL Server instances can take upwards of an hour to replace, especially if final snapshots are enabled. I was surprised to learn that most resources don't support modifying timeouts.

@sulabhk
Copy link

sulabhk commented Sep 4, 2020

+1, I second @fweep in having a configurable option wrt timeouts not just for WS, but for other services like RDS, Aurora etc that take longer times to be created/updated.

@aleliaert
Copy link

+1, am helping a Windows IT team move to the cloud with an infrastructure-as-code mindset. Don't want to retreat and use CloudFormation. Help appreciated!

@Tensho
Copy link
Contributor

Tensho commented Nov 19, 2020

Hi there, I've recently added timeout attributes to aws_workspaces_workspace resource. Please could you test them for your configuration? 🙇

@bflad bflad added the waiting-response Maintainers are waiting on response from community or contributor. label Nov 25, 2020
@bflad
Copy link
Contributor

bflad commented Jan 22, 2021

Given the resource now supports configurable timeouts and since there has been no further activity here, I'm going to close this issue.

@bflad bflad closed this as completed Jan 22, 2021
@ghost
Copy link

ghost commented Feb 22, 2021

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked as resolved and limited conversation to collaborators Feb 22, 2021
@breathingdust breathingdust removed the waiting-response Maintainers are waiting on response from community or contributor. label Sep 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Addresses a defect in current functionality. service/workspaces Issues and PRs that pertain to the workspaces service.
Projects
None yet
Development

No branches or pull requests

6 participants