title: Why does creating a bucket with Terraform throw "The provider provider.aws does not support resource type "aws_s3"" error?
body: <p>I am trying to create an S3 bucket using the following terraform code:</p>
  
  <p>provider.tf</p>
  
  <pre><code>provider "aws" {
    access_key = "XX"
    secret_key = "YY"
    region = "us-east-2"
  }
  
  </code></pre>
  
  <p>main.tf</p>
  
  <pre><code>resource "aws_s3" "bucket" {
    bucket = "terraform-s3-bucket"
    acl = "private"
  
    tags = {
      Name = "My Bucket"
      Environment = "Test"
    }
  }
  
  </code></pre>
  
  <p>However when I run <code>terraform apply</code> on the above code, I get this error:</p>
  
  <pre><code>Error: Invalid resource type
  
    on main.tf line 1, in resource "aws_s3" "bucket":
     1: resource "aws_s3" "bucket" {
  
  The provider provider.aws does not support resource type "aws_s3".
  </code></pre>
  
  <p>What am I doing wrong?</p>