You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to run an apply with dflook/terraform-apply@v1 and it consistently fails. Both fmt-check and validate actions do work correctly on the same repository.
I've tried forcing workspace to an empty string and leaving the variable out with similar results.
╷
│ Error: failed to create backend alias to target "". The hostname is not in the correct format.
│
│
╵
╷
│ Error: Invalid workspaces configuration
│
│ on service.tf line 7, in terraform:
│ 7: cloud {
│
│ Specified workspace "name" conflicts with TF_WORKSPACE environment
│ variable.
### Workflow log
```shell
Run dflook/terraform-apply@v1
with:
path: terraform/
auto_approve: true
parallelism: 0
destroy: false
env:
TERRAFORM_CLOUD_TOKENS: app.terraform.io=***
/usr/bin/docker run --name danielflookterraformgithubactionssha256445be2ccdfef4d1d3bd258f00582319c886969b76c1b848925022f8cbe4c6c7b_5fa9b7 --label 94351b --workdir /github/workspace --rm -e "TERRAFORM_CLOUD_TOKENS" -e "INPUT_PATH" -e "INPUT_AUTO_APPROVE" -e "INPUT_WORKSPACE" -e "INPUT_BACKEND_CONFIG" -e "INPUT_BACKEND_CONFIG_FILE" -e "INPUT_VARIABLES" -e "INPUT_VAR" -e "INPUT_VAR_FILE" -e "INPUT_PARALLELISM" -e "INPUT_LABEL" -e "INPUT_TARGET" -e "INPUT_REPLACE" -e "INPUT_DESTROY" -e "HOME" -e "GITHUB_JOB" -e "GITHUB_REF" -e "GITHUB_SHA" -e "GITHUB_REPOSITORY" -e "GITHUB_REPOSITORY_OWNER" -e "GITHUB_REPOSITORY_OWNER_ID" -e "GITHUB_RUN_ID" -e "GITHUB_RUN_NUMBER" -e "GITHUB_RETENTION_DAYS" -e "GITHUB_RUN_ATTEMPT" -e "GITHUB_REPOSITORY_ID" -e "GITHUB_ACTOR_ID" -e "GITHUB_ACTOR" -e "GITHUB_TRIGGERING_ACTOR" -e "GITHUB_WORKFLOW" -e "GITHUB_HEAD_REF" -e "GITHUB_BASE_REF" -e "GITHUB_EVENT_NAME" -e "GITHUB_SERVER_URL" -e "GITHUB_API_URL" -e "GITHUB_GRAPHQL_URL" -e "GITHUB_REF_NAME" -e "GITHUB_REF_PROTECTED" -e "GITHUB_REF_TYPE" -e "GITHUB_WORKFLOW_REF" -e "GITHUB_WORKFLOW_SHA" -e "GITHUB_WORKSPACE" -e "GITHUB_ACTION" -e "GITHUB_EVENT_PATH" -e "GITHUB_ACTION_REPOSITORY" -e "GITHUB_ACTION_REF" -e "GITHUB_PATH" -e "GITHUB_ENV" -e "GITHUB_STEP_SUMMARY" -e "GITHUB_STATE" -e "GITHUB_OUTPUT" -e "GITHUB_ACTION_PATH" -e "RUNNER_OS" -e "RUNNER_ARCH" -e "RUNNER_NAME" -e "RUNNER_ENVIRONMENT" -e "RUNNER_TOOL_CACHE" -e "RUNNER_TEMP" -e "RUNNER_WORKSPACE" -e "ACTIONS_RUNTIME_URL" -e "ACTIONS_RUNTIME_TOKEN" -e "ACTIONS_CACHE_URL" -e GITHUB_ACTIONS=true -e CI=true --entrypoint "/entrypoints/apply.sh" -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/hubot/hubot":"/github/workspace" danielflook/terraform-github-actions@sha256:445be2ccdfef4d1d3bd258f00582319c886969b76c1b848925022f8cbe4c6c7b
Installing Terraform
gpg: Signature made Tue Oct 10 16:10:49 2023 UTC
gpg: using RSA key 374EC75B485913604A831CC7C820C6D5CD27AB87
gpg: Good signature from "HashiCorp Security (hashicorp.com/security) <security@hashicorp.com>" [ultimate]
terraform_1.6.1_linux_amd64.zip: OK
Terraform version not specified, using the latest version
Switched to Terraform v1.6.1
Detected cloud backend
Initializing Terraform
Initializing Terraform Cloud...
╷
│ Error: failed to create backend alias to target "". The hostname is not in the correct format.
│
│
╵
╷
│ Error: Invalid workspaces configuration
│
│ on service.tf line 7, in terraform:
│ 7: cloud {
│
│ Specified workspace "name" conflicts with TF_WORKSPACE environment
│ variable.
│
│ The 'workspaces' block configures how Terraform CLI maps its workspaces for
│ this single
│ configuration to workspaces within a Terraform Cloud organization. Two
│ strategies are available:
│
│ tags - A set of tags used to select remote Terraform Cloud
│ workspaces to be used for this single
│ configuration. New workspaces will automatically be tagged with these tag
│ values. Generally, this
│ is the primary and recommended strategy to use. This option conflicts with
│ "name".
│
│ name - The name of a single Terraform Cloud workspace to be
│ used with this configuration.
│ When configured, only the specified workspace can be used. This option
│ conflicts with "tags"
│ and with the TF_WORKSPACE environment variable.
Has debug logging been enabled?
Yes, the ACTIONS_STEP_DEBUG secret was set to true when capturing the workflow log above.
The text was updated successfully, but these errors were encountered:
Problem description
Trying to run an apply with
dflook/terraform-apply@v1
and it consistently fails. Bothfmt-check
andvalidate
actions do work correctly on the same repository.I've tried forcing
workspace
to an empty string and leaving the variable out with similar results.Actual offending Terraform code:
Terraform version
1.6.1 (locally), 1.5.7 (remote)
Backend
Terraform Cloud
Workflow YAML
Has debug logging been enabled?
ACTIONS_STEP_DEBUG
secret was set totrue
when capturing the workflow log above.The text was updated successfully, but these errors were encountered: