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

Add note regarding terraform cloud execution mode #44

Merged
merged 2 commits into from
Feb 15, 2022
Merged

Add note regarding terraform cloud execution mode #44

merged 2 commits into from
Feb 15, 2022

Conversation

elliotblackburn
Copy link
Contributor

When configuring a workspace in Terraform Cloud, the execution mode defaults to "Remote". This is problematic for two reasons:

  1. The secrets / keys entered on the tfvars ansible step will be ignored, but the error doesn't make it immediately obvious that it's because the remote runner doesn't get the local terraform.tfvars file so the problem is slightly hidden.
  2. We use local files that are not in the terraform plan directory. This could also result in a similar issue above I think as it won't be able to locate some of the requested files.
  3. The remote (cloud) runner won't be able to access the kube cluster running on the internal network anyway, so any plan application will fail.

This tripped me up for a couple moments around trying to consume the api keys until I realised that what it had defaulted to. Hopefully this note will help prevent that issue for some others.

When configuring a workspace in Terraform Cloud, the execution mode defaults to "Remote". This is problematic for two reasons:
1. We use local files that are not in the terraform plan directory. This creates errors about being unable to local files where it is not immediately obvious why.
2. The remote (cloud) runner won't be able to access the kube cluster running on the internal network anyway, so any plan application will fail.
@khuedoan
Copy link
Owner

Thanks, but can you add the full instruction to this section instead, I have a TODO there

### Create Terraform workspace

@elliotblackburn
Copy link
Contributor Author

Sure, I've added some basic instructions to that now.

Copy link
Owner

@khuedoan khuedoan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, thank you!

@khuedoan khuedoan merged commit cf94f76 into khuedoan:master Feb 15, 2022
@elliotblackburn elliotblackburn deleted the patch-1 branch February 15, 2022 10:57
zanehala added a commit to zanehala/homelab that referenced this pull request Mar 18, 2023
retX0 pushed a commit to retX0/homelab that referenced this pull request Mar 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants