mirror of
https://github.com/microsoft/onefuzz.git
synced 2025-06-18 20:58:06 +00:00
NSG Updated After CLI Update to Instance_Config (#1375)
* Creating InstanceConfig Attributes for NSG Refactor (#1331) * Updating instance_config * Updating attribute names. * Updating list factory. * Updating config attributes. Co-authored-by: nharper285 <nharper285@gmail.com> * NSG deployment on a creation of new debug/repro proxy. (#1340) Co-authored-by: stas <statis@microsoft.com> * Code for updating NSGs when instance_config updated. * Updating argument to set_allowed_rules * Temporarily ignore non-actionable `cargo audit` errors (#1365) * Updating model to no longer be optional. * Fixing args for set_allowed_rules * trying to fix calls to get_nsg * Updating calls to nsg lib * Fixing imports. * Updating calls to set_allowed and creating constructor for NSGConfig type. * Removing constructor and manually setting default ip * Fixing models. * Hopefully fixing docs. * Fix set_allowed call * Adding error handling for update config. * Changing to error check. * Fixing error call. * Fixing imports. * Updating instanceconfig retrieval. * Fixing imports. * Adding empty() function on request. * Fixing name of function. * Removing empty function. Co-authored-by: nharper285 <nharper285@gmail.com> Co-authored-by: Stas <stishkin@live.com> Co-authored-by: stas <statis@microsoft.com> Co-authored-by: Joe Ranweiler <joranwei@microsoft.com>
This commit is contained in:
committed by
GitHub
parent
97a3a67b3e
commit
357bc4fcad
@ -799,6 +799,11 @@ class NetworkConfig(BaseModel):
|
||||
subnet: str = Field(default="10.0.0.0/16")
|
||||
|
||||
|
||||
class NetworkSecurityGroupConfig(BaseModel):
|
||||
allowed_service_tags: List[str] = Field(default_factory=list)
|
||||
allowed_ips: List[str] = Field(default_factory=list)
|
||||
|
||||
|
||||
class KeyvaultExtensionConfig(BaseModel):
|
||||
keyvault_name: str
|
||||
cert_name: str
|
||||
@ -841,6 +846,9 @@ class InstanceConfig(BaseModel):
|
||||
|
||||
allowed_aad_tenants: List[UUID]
|
||||
network_config: NetworkConfig = Field(default_factory=NetworkConfig)
|
||||
proxy_nsg_config: NetworkSecurityGroupConfig = Field(
|
||||
default_factory=NetworkSecurityGroupConfig
|
||||
)
|
||||
extensions: Optional[AzureVmExtensionConfig]
|
||||
proxy_vm_sku: str = Field(default="Standard_B2s")
|
||||
|
||||
|
Reference in New Issue
Block a user