-
Notifications
You must be signed in to change notification settings - Fork 708
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
Add ip_configuration block to private endpoints #1691
Merged
arnaudlh
merged 10 commits into
aztfmod:main
from
fschirinzi:add-ip-configuration-to-private-endpoints
Aug 3, 2023
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
0816040
add ip_configuration to private endpoints
fschirinzi-zue b488ec6
private endpoint update ip_configuration
fschirinzi-zue 09ac6b6
tf format
fschirinzi-zue ffea9de
add example
fschirinzi-zue 0dc1763
fix private_endpoint static ip config
fschirinzi bccaae3
update private endpoint static ip example
fschirinzi-zue c072308
Update examples/networking/private_endpoint/configuration.tfvars
fschirinzi 69ce3d6
private endpoint: add multi ip_configuration
fschirinzi-zue b8a5d87
fix docs
fschirinzi-zue a090d22
add example to workflows
fschirinzi-zue File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,19 @@ | ||||||||||
You can test this module outside of a landingzone using | ||||||||||
|
||||||||||
```bash | ||||||||||
sudo terraform init | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||
|
||||||||||
terraform [plan|apply|destroy] \ | ||||||||||
-var-file ../configuration.tfvars \ | ||||||||||
-var-file ../keyvaults.tfvars \ | ||||||||||
-var-file ../nsg_definitions.tfvars \ | ||||||||||
-var-file ../virtual_networks.tfvars \ | ||||||||||
-var-file ../public_ip_addresses.tfvars \ | ||||||||||
-var-file ../virtual_machines.tfvars | ||||||||||
|
||||||||||
|
||||||||||
``` | ||||||||||
|
||||||||||
sudo terraform plan -var-file examples/networking/private_endpoint/configuration.tfvars | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||
|
||||||||||
sudo terraform plan -var-file configuration.tfvars |
100 changes: 100 additions & 0 deletions
100
examples/networking/private_endpoint/configuration.tfvars
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,100 @@ | ||
global_settings = { | ||
default_region = "region1" | ||
regions = { | ||
region1 = "australiaeast" | ||
} | ||
} | ||
|
||
resource_groups = { | ||
kv_region1 = { | ||
name = "keyvault-rg1" | ||
region = "region1" | ||
} | ||
} | ||
|
||
keyvaults = { | ||
|
||
# | ||
# Keyvault with private endpoint enabled and configured with two static ips | ||
# | ||
kv01_rg1 = { | ||
name = "certificates" | ||
resource_group_key = "kv_region1" | ||
sku_name = "premium" | ||
|
||
creation_policies = { | ||
logged_in_user = { | ||
secret_permissions = ["Set", "Get", "List", "Delete", "Purge"] | ||
certificate_permissions = ["ManageContacts", "ManageIssuers"] | ||
} | ||
} | ||
|
||
network = { | ||
bypass = "AzureServices" | ||
default_action = "Deny" | ||
} | ||
|
||
private_endpoints = { | ||
# Require enforce_private_link_endpoint_network_policies set to true on the subnet | ||
private-link1 = { | ||
name = "keyvault-certificates" | ||
vnet_key = "vnet_security" | ||
subnet_key = "private_link" | ||
resource_group_key = "kv_region1" | ||
# if the private_endpoint must be deployed in a remote resource group | ||
# resource_group = { | ||
# lz_key = "" | ||
# key = "" | ||
# } | ||
|
||
private_service_connection = { | ||
name = "keyvault-certificates" | ||
is_manual_connection = false | ||
subresource_names = ["vault"] | ||
} | ||
|
||
ip_configurations = { | ||
static1= { | ||
name = "kv01_rg1-name1" | ||
private_ip_address = "10.150.100.140" | ||
subresource_name = "vault" | ||
member_name = "default" | ||
} | ||
static2 = { | ||
name = "kv01_rg1-name2" | ||
private_ip_address = "10.150.100.150" | ||
subresource_name = "vault" | ||
member_name = "default2" | ||
} | ||
} | ||
|
||
# private_dns = { | ||
# lz_key = "" | ||
# keys = ["vaultcore"] | ||
# } | ||
} | ||
} | ||
} | ||
} | ||
|
||
vnets = { | ||
vnet_security = { | ||
resource_group_key = "kv_region1" | ||
vnet = { | ||
name = "keyvaults" | ||
address_space = ["10.150.100.0/24"] | ||
} | ||
subnets = { | ||
keyvault_endpoints = { | ||
name = "keyvault" | ||
cidr = ["10.150.100.64/26"] | ||
service_endpoints = ["Microsoft.KeyVault"] | ||
} | ||
private_link = { | ||
name = "private-links" | ||
cidr = ["10.150.100.128/26"] | ||
enforce_private_link_endpoint_network_policies = true | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.