Answers: <p>The problem I had to generate this was my provider had an alias,</p>
  <pre><code>provider &quot;openstack&quot; {
    alias       = &quot;acmecorp&quot;
    tenant_name = &quot;admin&quot;
    cloud       = &quot;openstack&quot;
  }
  </code></pre>
  <p>That <code>alias</code> caused this problem, and removing it resolved the error. But looking at the specific <a href="https://registry.terraform.io/providers/terraform-provider-openstack/openstack/latest/docs" rel="nofollow noreferrer"><code>terraform-provider-openstack/openstack</code> provider documentation</a> <code>alias</code> isn't mentioned. I pulled the alias convention from AWS and it seems to not be supported with OpenStack.</p>
  <p><a href="https://github.com/terraform-provider-openstack/terraform-provider-openstack/issues/1480" rel="nofollow noreferrer">I opened #1480 for a better error message</a></p>
  
Answers: CC BY-SA 4.0
Answers: 2023-02-15T19:05:37.030Z
Answers: 2023-02-15T19:05:37.030Z
Answers: Evan Carroll
Body: <p>When I run <code>terraform apply</code> (but not <code>terraform validate</code>) I get the following error,</p>
  <blockquote>
  <p>Error: Invalid provider configuration</p>
  <p>Provider &quot;registry.terraform.io/terraform-provider-openstack/openstack&quot; requires explicit configuration. Add a provider block to the root module and configure the provider's required arguments as described in the provider documentation.</p>
  </blockquote>
  <p>Immediately followed by,</p>
  <blockquote>
  <p>Error: One of <code>auth_url</code> or <code>cloud</code> must be specified</p>
  <pre><code> with provider[&quot;registry.terraform.io/terraform-provider-openstack/openstack&quot;],
   on &lt;empty&gt; line 0:
     (source code not available)
  </code></pre>
  </blockquote>
  <p>How can I resolve this problem?</p>
  
Tags: <terraform><openstack>
Title: Terraform's OpenStack provider: Error: One of 'auth_url` or 'cloud` must be specified
UserDisplayName: Evan Carroll
ThreadText: # Terraform's OpenStack provider: Error: One of 'auth_url` or 'cloud` must be specified
  
  (Asked by: username_0 on 2023-02-15)
  
  When I run `terraform apply` (but not `terraform validate`) I get the following error,
  
  > Error: Invalid provider configuration
  >
  > Provider "registry.terraform.io/terraform-provider-openstack/openstack" requires explicit configuration. Add a provider block to the root module and configure the provider's required arguments as described in the provider documentation.
  
  Immediately followed by,
  
  > Error: One of `auth_url` or `cloud` must be specified
  >
  > ```
  >  with provider["registry.terraform.io/terraform-provider-openstack/openstack"],
  >  on <empty> line 0:
  >    (source code not available)
  >
  > ```
  
  How can I resolve this problem?
  
  **Tags:** terraform, openstack
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2023-02-15. Score: 0 | Accepted answer
  
  The problem I had to generate this was my provider had an alias,
  
  ```
  provider "openstack" {
    alias       = "acmecorp"
    tenant_name = "admin"
    cloud       = "openstack"
  }
  
  ```
  
  That `alias` caused this problem, and removing it resolved the error. But looking at the specific [`terraform-provider-openstack/openstack` provider documentation](https://registry.terraform.io/providers/terraform-provider-openstack/openstack/latest/docs) `alias` isn't mentioned. I pulled the alias convention from AWS and it seems to not be supported with OpenStack.
  
  [I opened #1480 for a better error message](https://github.com/terraform-provider-openstack/terraform-provider-openstack/issues/1480)
  
  
  ---
  
  