Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Introduce Terraform 1.6 and 1.7 in CI workflows, fix README and update test skeleton version #7

Merged
merged 3 commits into from
Feb 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/pr_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
secrets: inherit
with:
cloud: aws
tf_version: 1.2 1.3 1.4 1.5
tf_version: 1.2 1.3 1.4 1.5 1.6 1.7
validate_max_parallel: 20
test_max_parallel: 10
terratest_action: Plan # keep in mind that this has to start with capital letter
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,5 @@ modules/asg/scripts/bin/
modules/asg/scripts/pan/
modules/asg/scripts/pan_os_python-1.11.0.dist-info/
modules/asg/scripts/pan_python-0.17.0.dist-info/
modules/asg/scripts/panos/
modules/asg/scripts/panos/
go.sum
148 changes: 74 additions & 74 deletions examples/centralized_design_autoscale/README.md

Large diffs are not rendered by default.

148 changes: 74 additions & 74 deletions examples/combined_design/README.md

Large diffs are not rendered by default.

138 changes: 69 additions & 69 deletions examples/combined_design_autoscale/README.md

Large diffs are not rendered by default.

132 changes: 66 additions & 66 deletions examples/isolated_design_autoscale/README.md

Large diffs are not rendered by default.

104 changes: 52 additions & 52 deletions examples/panorama_standalone/README.md

Large diffs are not rendered by default.

94 changes: 47 additions & 47 deletions examples/vmseries_standalone/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,51 +64,51 @@ Use a web browser to access https://x.x.x.x and login with admin and your previo

## Reference
<!-- BEGINNING OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
### Requirements
| Name | Version |
|------|---------|
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0.0, < 2.0.0 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | ~> 5.17 |
### Providers
| Name | Version |
|------|---------|
| <a name="provider_aws"></a> [aws](#provider\_aws) | ~> 5.17 |
### Modules
| Name | Source | Version |
|------|--------|---------|
| <a name="module_bootstrap"></a> [bootstrap](#module\_bootstrap) | ../../modules/bootstrap | n/a |
| <a name="module_subnet_sets"></a> [subnet\_sets](#module\_subnet\_sets) | ../../modules/subnet_set | n/a |
| <a name="module_vmseries"></a> [vmseries](#module\_vmseries) | ../../modules/vmseries | n/a |
| <a name="module_vpc"></a> [vpc](#module\_vpc) | ../../modules/vpc | n/a |
| <a name="module_vpc_routes"></a> [vpc\_routes](#module\_vpc\_routes) | ../../modules/vpc_route | n/a |
### Resources
| Name | Type |
|------|------|
| [aws_iam_role_policy.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role_policy) | resource |
| [aws_caller_identity.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/caller_identity) | data source |
| [aws_partition.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/partition) | data source |
### Inputs
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| <a name="input_global_tags"></a> [global\_tags](#input\_global\_tags) | Global tags configured for all provisioned resources | `any` | n/a | yes |
| <a name="input_name_prefix"></a> [name\_prefix](#input\_name\_prefix) | Prefix used in names for the resources (VPCs, EC2 instances, autoscaling groups etc.) | `string` | n/a | yes |
| <a name="input_region"></a> [region](#input\_region) | AWS region used to deploy whole infrastructure | `string` | n/a | yes |
| <a name="input_ssh_key_name"></a> [ssh\_key\_name](#input\_ssh\_key\_name) | Name of the SSH key pair existing in AWS key pairs and used to authenticate to VM-Series or test boxes | `string` | n/a | yes |
| <a name="input_vmseries"></a> [vmseries](#input\_vmseries) | A map defining VM-Series instances<br>Following properties are available:<br>- `instances`: map of VM-Series instances<br>- `bootstrap_options`: VM-Seriess bootstrap options used to connect to Panorama<br>- `panos_version`: PAN-OS version used for VM-Series<br>- `ebs_kms_id`: alias for AWS KMS used for EBS encryption in VM-Series<br>- `vpc`: key of VPC<br>Example:<pre>vmseries = {<br> vmseries = {<br> instances = {<br> "01" = { az = "eu-central-1a" }<br> }<br> # Value of `panorama-server`, `auth-key`, `dgname`, `tplname` can be taken from plugin `sw_fw_license`<br> bootstrap_options = {<br> mgmt-interface-swap = "enable"<br> plugin-op-commands = "panorama-licensing-mode-on,aws-gwlb-inspect:enable,aws-gwlb-overlay-routing:enable"<br> dhcp-send-hostname = "yes"<br> dhcp-send-client-id = "yes"<br> dhcp-accept-server-hostname = "yes"<br> dhcp-accept-server-domain = "yes"<br> }<br> panos_version = "10.2.3" # TODO: update here<br> ebs_kms_id = "alias/aws/ebs" # TODO: update here<br><br> # Value of `vpc` must match key of objects stored in `vpcs`<br> vpc = "security_vpc"<br><br> interfaces = {<br> mgmt = {<br> device_index = 1<br> private_ip = "10.100.0.4"<br> security_group = "vmseries_mgmt"<br> vpc_subnet = "security_vpc-mgmt"<br> create_public_ip = true<br> source_dest_check = true<br> eip_allocation_id = null<br> }<br> }<br> }<br>}</pre> | <pre>map(object({<br> instances = map(object({<br> az = string<br> }))<br><br> bootstrap_options = object({<br> mgmt-interface-swap = string<br> panorama-server = string<br> tplname = string<br> dgname = string<br> plugin-op-commands = string<br> dhcp-send-hostname = string<br> dhcp-send-client-id = string<br> dhcp-accept-server-hostname = string<br> dhcp-accept-server-domain = string<br> })<br><br> panos_version = string<br> ebs_kms_id = string<br><br> vpc = string<br><br> interfaces = map(object({<br> device_index = number<br> private_ip = map(string)<br> security_group = string<br> vpc_subnet = string<br> create_public_ip = bool<br> source_dest_check = bool<br> eip_allocation_id = map(string)<br> }))<br> }))</pre> | `{}` | no |
| <a name="input_vpcs"></a> [vpcs](#input\_vpcs) | A map defining VPCs with security groups and subnets.<br><br>Following properties are available:<br>- `name`: VPC name<br>- `cidr`: CIDR for VPC<br>- `nacls`: map of network ACLs<br>- `security_groups`: map of security groups<br>- `subnets`: map of subnets with properties:<br> - `az`: availability zone<br> - `set`: internal identifier referenced by main.tf<br> - `nacl`: key of NACL (can be null)<br>- `routes`: map of routes with properties:<br> - `vpc_subnet` - built from key of VPCs concatenate with `-` and key of subnet in format: `VPCKEY-SUBNETKEY`<br> - `next_hop_key` - must match keys use to create TGW attachment, IGW, GWLB endpoint or other resources<br> - `next_hop_type` - internet\_gateway, nat\_gateway, transit\_gateway\_attachment or gwlbe\_endpoint<br><br>Example:<pre>vpcs = {<br> example_vpc = {<br> name = "example-spoke-vpc"<br> cidr = "10.104.0.0/16"<br> nacls = {<br> trusted_path_monitoring = {<br> name = "trusted-path-monitoring"<br> rules = {<br> allow_inbound = {<br> rule_number = 300<br> egress = false<br> protocol = "-1"<br> rule_action = "allow"<br> cidr_block = "0.0.0.0/0"<br> from_port = null<br> to_port = null<br> }<br> }<br> }<br> }<br> security_groups = {<br> example_vm = {<br> name = "example_vm"<br> rules = {<br> all_outbound = {<br> description = "Permit All traffic outbound"<br> type = "egress", from_port = "0", to_port = "0", protocol = "-1"<br> cidr_blocks = ["0.0.0.0/0"]<br> }<br> }<br> }<br> }<br> subnets = {<br> "10.104.0.0/24" = { az = "eu-central-1a", set = "vm", nacl = null }<br> }<br> routes = {<br> vm_default = {<br> vpc_subnet = "app1_vpc-app1_vm"<br> to_cidr = "0.0.0.0/0"<br> next_hop_key = "app1"<br> next_hop_type = "transit_gateway_attachment"<br> }<br> }<br> }<br>}</pre> | <pre>map(object({<br> name = string<br> cidr = string<br> nacls = map(object({<br> name = string<br> rules = map(object({<br> rule_number = number<br> egress = bool<br> protocol = string<br> rule_action = string<br> cidr_block = string<br> from_port = string<br> to_port = string<br> }))<br> }))<br> security_groups = any<br> subnets = map(object({<br> az = string<br> set = string<br> nacl = string<br> }))<br> routes = map(object({<br> vpc_subnet = string<br> to_cidr = string<br> next_hop_key = string<br> next_hop_type = string<br> }))<br> }))</pre> | `{}` | no |
### Outputs
| Name | Description |
|------|-------------|
| <a name="output_vmseries_public_ips"></a> [vmseries\_public\_ips](#output\_vmseries\_public\_ips) | Map of public IPs created within `vmseries` module instances. |
### Requirements

| Name | Version |
|------|---------|
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0.0, < 2.0.0 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | ~> 5.17 |

### Providers

| Name | Version |
|------|---------|
| <a name="provider_aws"></a> [aws](#provider\_aws) | ~> 5.17 |

### Modules

| Name | Source | Version |
|------|--------|---------|
| <a name="module_bootstrap"></a> [bootstrap](#module\_bootstrap) | ../../modules/bootstrap | n/a |
| <a name="module_subnet_sets"></a> [subnet\_sets](#module\_subnet\_sets) | ../../modules/subnet_set | n/a |
| <a name="module_vmseries"></a> [vmseries](#module\_vmseries) | ../../modules/vmseries | n/a |
| <a name="module_vpc"></a> [vpc](#module\_vpc) | ../../modules/vpc | n/a |
| <a name="module_vpc_routes"></a> [vpc\_routes](#module\_vpc\_routes) | ../../modules/vpc_route | n/a |

### Resources

| Name | Type |
|------|------|
| [aws_iam_role_policy.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role_policy) | resource |
| [aws_caller_identity.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/caller_identity) | data source |
| [aws_partition.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/partition) | data source |

### Inputs

| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| <a name="input_global_tags"></a> [global\_tags](#input\_global\_tags) | Global tags configured for all provisioned resources | `any` | n/a | yes |
| <a name="input_name_prefix"></a> [name\_prefix](#input\_name\_prefix) | Prefix used in names for the resources (VPCs, EC2 instances, autoscaling groups etc.) | `string` | n/a | yes |
| <a name="input_region"></a> [region](#input\_region) | AWS region used to deploy whole infrastructure | `string` | n/a | yes |
| <a name="input_ssh_key_name"></a> [ssh\_key\_name](#input\_ssh\_key\_name) | Name of the SSH key pair existing in AWS key pairs and used to authenticate to VM-Series or test boxes | `string` | n/a | yes |
| <a name="input_vmseries"></a> [vmseries](#input\_vmseries) | A map defining VM-Series instances<br>Following properties are available:<br>- `instances`: map of VM-Series instances<br>- `bootstrap_options`: VM-Seriess bootstrap options used to connect to Panorama<br>- `panos_version`: PAN-OS version used for VM-Series<br>- `ebs_kms_id`: alias for AWS KMS used for EBS encryption in VM-Series<br>- `vpc`: key of VPC<br>Example:<pre>vmseries = {<br> vmseries = {<br> instances = {<br> "01" = { az = "eu-central-1a" }<br> }<br> # Value of `panorama-server`, `auth-key`, `dgname`, `tplname` can be taken from plugin `sw_fw_license`<br> bootstrap_options = {<br> mgmt-interface-swap = "enable"<br> plugin-op-commands = "panorama-licensing-mode-on,aws-gwlb-inspect:enable,aws-gwlb-overlay-routing:enable"<br> dhcp-send-hostname = "yes"<br> dhcp-send-client-id = "yes"<br> dhcp-accept-server-hostname = "yes"<br> dhcp-accept-server-domain = "yes"<br> }<br> panos_version = "10.2.3" # TODO: update here<br> ebs_kms_id = "alias/aws/ebs" # TODO: update here<br><br> # Value of `vpc` must match key of objects stored in `vpcs`<br> vpc = "security_vpc"<br><br> interfaces = {<br> mgmt = {<br> device_index = 1<br> private_ip = "10.100.0.4"<br> security_group = "vmseries_mgmt"<br> vpc_subnet = "security_vpc-mgmt"<br> create_public_ip = true<br> source_dest_check = true<br> eip_allocation_id = null<br> }<br> }<br> }<br>}</pre> | <pre>map(object({<br> instances = map(object({<br> az = string<br> }))<br><br> bootstrap_options = object({<br> mgmt-interface-swap = string<br> panorama-server = string<br> tplname = string<br> dgname = string<br> plugin-op-commands = string<br> dhcp-send-hostname = string<br> dhcp-send-client-id = string<br> dhcp-accept-server-hostname = string<br> dhcp-accept-server-domain = string<br> })<br><br> panos_version = string<br> ebs_kms_id = string<br><br> vpc = string<br><br> interfaces = map(object({<br> device_index = number<br> private_ip = map(string)<br> security_group = string<br> vpc_subnet = string<br> create_public_ip = bool<br> source_dest_check = bool<br> eip_allocation_id = map(string)<br> }))<br> }))</pre> | `{}` | no |
| <a name="input_vpcs"></a> [vpcs](#input\_vpcs) | A map defining VPCs with security groups and subnets.<br><br>Following properties are available:<br>- `name`: VPC name<br>- `cidr`: CIDR for VPC<br>- `nacls`: map of network ACLs<br>- `security_groups`: map of security groups<br>- `subnets`: map of subnets with properties:<br> - `az`: availability zone<br> - `set`: internal identifier referenced by main.tf<br> - `nacl`: key of NACL (can be null)<br>- `routes`: map of routes with properties:<br> - `vpc_subnet` - built from key of VPCs concatenate with `-` and key of subnet in format: `VPCKEY-SUBNETKEY`<br> - `next_hop_key` - must match keys use to create TGW attachment, IGW, GWLB endpoint or other resources<br> - `next_hop_type` - internet\_gateway, nat\_gateway, transit\_gateway\_attachment or gwlbe\_endpoint<br><br>Example:<pre>vpcs = {<br> example_vpc = {<br> name = "example-spoke-vpc"<br> cidr = "10.104.0.0/16"<br> nacls = {<br> trusted_path_monitoring = {<br> name = "trusted-path-monitoring"<br> rules = {<br> allow_inbound = {<br> rule_number = 300<br> egress = false<br> protocol = "-1"<br> rule_action = "allow"<br> cidr_block = "0.0.0.0/0"<br> from_port = null<br> to_port = null<br> }<br> }<br> }<br> }<br> security_groups = {<br> example_vm = {<br> name = "example_vm"<br> rules = {<br> all_outbound = {<br> description = "Permit All traffic outbound"<br> type = "egress", from_port = "0", to_port = "0", protocol = "-1"<br> cidr_blocks = ["0.0.0.0/0"]<br> }<br> }<br> }<br> }<br> subnets = {<br> "10.104.0.0/24" = { az = "eu-central-1a", set = "vm", nacl = null }<br> }<br> routes = {<br> vm_default = {<br> vpc_subnet = "app1_vpc-app1_vm"<br> to_cidr = "0.0.0.0/0"<br> next_hop_key = "app1"<br> next_hop_type = "transit_gateway_attachment"<br> }<br> }<br> }<br>}</pre> | <pre>map(object({<br> name = string<br> cidr = string<br> nacls = map(object({<br> name = string<br> rules = map(object({<br> rule_number = number<br> egress = bool<br> protocol = string<br> rule_action = string<br> cidr_block = string<br> from_port = string<br> to_port = string<br> }))<br> }))<br> security_groups = any<br> subnets = map(object({<br> az = string<br> set = string<br> nacl = string<br> }))<br> routes = map(object({<br> vpc_subnet = string<br> to_cidr = string<br> next_hop_key = string<br> next_hop_type = string<br> }))<br> }))</pre> | `{}` | no |

### Outputs

| Name | Description |
|------|-------------|
| <a name="output_vmseries_public_ips"></a> [vmseries\_public\_ips](#output\_vmseries\_public\_ips) | Map of public IPs created within `vmseries` module instances. |
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/PaloAltoNetworks/terraform-aws-swfw-modules
go 1.20

require (
github.com/PaloAltoNetworks/terraform-modules-swfw-tests-skeleton v1.1.0
github.com/PaloAltoNetworks/terraform-modules-swfw-tests-skeleton v1.2.0
github.com/gruntwork-io/terratest v0.43.6
github.com/hashicorp/terraform-json v0.17.1
)
Expand Down
Loading
Loading