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

fix(azure VM agents): revert to outgoing port 22 to internet for packer-images build #163

Merged
merged 1 commit into from
Dec 5, 2024
Merged
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
9 changes: 5 additions & 4 deletions terraform/modules/azure-jenkinsinfra-azurevm-agents/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,12 @@ resource "azurerm_network_security_rule" "allow_outbound_ssh_from_ephemeral_agen
source_port_range = "*"
source_address_prefixes = data.azurerm_subnet.ephemeral_agents.address_prefixes
destination_port_range = "22"
destination_address_prefix = "Internet" # setting back to all internet as it crash the packer-images build
#Filter only for ipv4 ips
destination_address_prefixes = [
for ip in split(" ", local.github_destination_address_prefixes) : ip
if can(cidrnetmask(ip))
]
#destination_address_prefixes = [
# for ip in split(" ", local.github_destination_address_prefixes) : ip
# if can(cidrnetmask(ip))
#]
resource_group_name = var.controller_rg_name
network_security_group_name = azurerm_network_security_group.ephemeral_agents.name
}
Expand Down