Skip to content

hadenlabs/terraform-aws-s3-bucket

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

5 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Latest Release Lint CI Test pre-commit Conventional Commits KeepAChangelog Terraform Version AWS Provider Version

terraform-aws-s3-bucket

terraform-aws-s3-bucket for project

Requirements

This is a list of plugins that need to be installed previously to enjoy all the goodies of this configuration:

Usage

How to use this project

  module "main" {
    source  = "hadenlabs/s3-bucket/aws"
    version = "0.0.0"
  }

Full working examples can be found in examples folder.

Examples

common

  module "main" {
    source  = "hadenlabs/s3-bucket/aws"
    version = "0.1.0"
  }

Requirements

Name Version
terraform >= 0.12.20, < 2.0
aws >= 2.51, < 4.0

Providers

Name Version
aws >= 2.51, < 4.0

Modules

Name Source Version
s3_user hadenlabs/iam-s3-user/aws >=0.1
tags hadenlabs/tags/null >=0.2

Resources

Name Type
aws_s3_bucket.this resource

Inputs

Name Description Type Default Required
acl The canned ACL to apply. string "private" no
allowed_bucket_actions List of actions the user is permitted to perform on the S3 bucket list(string)
[
"s3:PutObject",
"s3:PutObjectAcl",
"s3:GetObject",
"s3:DeleteObject",
"s3:ListBucket",
"s3:ListBucketMultipartUploads",
"s3:GetBucketLocation",
"s3:AbortMultipartUpload"
]
no
enabled Set to false to prevent the module from creating any resources bool true no
force_destroy A boolean string that indicates all objects should be deleted from the bucket so that the bucket can be destroyed without error. These objects are not recoverable bool false no
name Bucket name. If provided, the bucket will be created with this name instead of generating the name from the context string null no
namespace ID element. Usually an abbreviation of your organization name, e.g. 'eg' or 'cp', to help ensure generated IDs are globally unique string null no
stage ID element. Usually used to indicate role, e.g. 'prod', 'staging', 'source', 'build', 'test', 'deploy', 'release' string null no
tags Additional tags (e.g. map('BusinessUnit','XYZ') map(string) {} no
use_fullname Set to true to make name using namespace + stage + name on resource bool false no
user_enabled Set to true to create an IAM user with permission to access the bucket bool false no
versioning_enabled A state of versioning. Versioning is a means of keeping multiple variants of an object in the same bucket bool true no

Outputs

Name Description
access_key_id The access key ID
bucket_arn Bucket ARN
bucket_domain_name FQDN of bucket
bucket_id Bucket Name (aka ID)
bucket_region bucket region
bucket_regional_domain_name The bucket region-specific domain name
instance instance bucket.
secret_access_key The secret access key. This will be written to the state file in plain-text
tags tags generated
use_fullname return if enabled generated name
user_arn The ARN assigned by AWS for the user
user_enabled Is user creation enabled
user_name Normalized IAM user name
user_unique_id The user unique ID assigned by AWS

Help

Got a question?

File a GitHub issue.

Contributing

See Contributing.

Module Versioning

This Module follows the principles of Semantic Versioning (SemVer).

Using the given version number of MAJOR.MINOR.PATCH, we apply the following constructs:

  1. Use the MAJOR version for incompatible changes.
  2. Use the MINOR version when adding functionality in a backwards compatible manner.
  3. Use the PATCH version when introducing backwards compatible bug fixes.

Backwards compatibility in 0.0.z and 0.y.z version

  • In the context of initial development, backwards compatibility in versions 0.0.z is not guaranteed when z is increased. (Initial development)
  • In the context of pre-release, backwards compatibility in versions 0.y.z is not guaranteed when y is increased. (Pre-release)

Copyright

Copyright Β© 2018-2022 Hadenlabs

Trademarks

All other trademarks referenced herein are the property of their respective owners.

License

The code and styles are licensed under the LGPL-3.0 license See project license..

Don't forget to 🌟 Star 🌟 the repo if you like terraform-aws-s3-bucket

Your feedback is appreciated