A Terraform module for creating and managing a Cloudfare Web Application Firewall resource.
_This module supports Terraform version 0.14.7 up to (not including) version 2.0 and is compatible with the Terraform Cloudfare Provider version 3
This module is part of our Infrastructure as Code (IaC) framework that enables our users and customers to easily deploy and manage reusable, secure, and production-grade cloud infrastructure.
- Module Features
- Getting Started
- Module Argument Reference
- Module Outputs
- External Documentation
- Module Versioning
- About Mineiros
- Reporting Issues
- Contributing
- Makefile Targets
- License
This module implements the following Terraform resources
cloudflare_waf_packages
cloudflare_waf_package
cloudflare_waf_group
cloudflare_waf_rule
Most common usage of the module:
module "terraform-cloudflare-waf" {
source = "[email protected]:mineiros-io/terraform-cloudflare-waf.git?ref=v0.1.1"
zone_id = "zone-id"
package_id = "package-id"
}
See variables.tf and examples/ for details and use-cases.
-
zone_id
: (Requiredstring
)The DNS zone ID to apply to.
-
package_id
: (Requiredstring
)The WAF Package ID.
-
sensitivity
: (Optionalstring
)The sensitivity of the package, can be one of ['high', 'medium', 'low', 'off'].
-
action_mode
: (Optionalstring
)The action mode of the package, can be one of ['block', 'challenge', 'simulate'].
-
groups
: (Optionallist(group)
)A list of WAF groups.
Default is
[]
.Each
group
object in the list accepts the following attributes: -
rules
: (Optionallist(rule)
)A list of WAF rules.
Default is
[]
.Each
rule
object in the list accepts the following attributes:
-
module_enabled
: (Optionalbool
)Specifies whether resources in the module will be created.
Default is
true
. -
module_depends_on
: (Optionallist(dependency)
)A list of dependencies. Any object can be assigned to this list to define a hidden external dependency.
Default is
[]
.Example:
module_depends_on = [ null_resource.name ]
The following attributes are exported in the outputs of the module:
-
package
: (object(package)
)All
cloudflare_waf_package
resource attributes. -
groups
: (map(groups)
)All
cloudflare_waf_group
resource attributes. -
rules
: (map(rules)
)All
cloudflare_waf_rule
resource attributes. -
module_enabled
: (bool
)Whether this module is enabled.
- https://registry.terraform.io/providers/cloudflare/cloudflare/latest/docs/resources/waf_group
- https://registry.terraform.io/providers/cloudflare/cloudflare/latest/docs/resources/waf_package
- https://registry.terraform.io/providers/cloudflare/cloudflare/latest/docs/resources/waf_rule
- https://registry.terraform.io/providers/cloudflare/cloudflare/latest/docs/data-sources/waf_packages
This Module follows the principles of Semantic Versioning (SemVer).
Given a version number MAJOR.MINOR.PATCH
, we increment the:
MAJOR
version when we make incompatible changes,MINOR
version when we add functionality in a backwards compatible manner, andPATCH
version when we make backwards compatible bug fixes.
- Backwards compatibility in versions
0.0.z
is not guaranteed whenz
is increased. (Initial development) - Backwards compatibility in versions
0.y.z
is not guaranteed wheny
is increased. (Pre-release)
Mineiros is a remote-first company headquartered in Berlin, Germany that solves development, automation and security challenges in cloud infrastructure.
Our vision is to massively reduce time and overhead for teams to manage and deploy production-grade and secure cloud infrastructure.
We offer commercial support for all of our modules and encourage you to reach out if you have any questions or need help. Feel free to email us at [email protected] or join our Community Slack channel.
We use GitHub Issues to track community reported issues and missing features.
Contributions are always encouraged and welcome! For the process of accepting changes, we use Pull Requests. If you'd like more information, please see our Contribution Guidelines.
This repository comes with a handy Makefile.
Run make help
to see details on each available target.
This module is licensed under the Apache License Version 2.0, January 2004. Please see LICENSE for full details.
Copyright © 2020-2022 Mineiros GmbH