vdc/Modules
msftkenneth 567dc8eeb2
Add sourceAddressPrefixes to the Resource section (#164)
It is probably missed to add the suggested line to cater multiple values in array form for the source address prefixes.
2020-08-18 16:21:43 -07:00
..
APIManagement fix tag values to provide an empty object (#154) 2019-11-06 16:03:55 -08:00
ActiveDirectory Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
ActiveDirectoryDomainServices Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
AnalysisServices Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
AppServiceEnvironments Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
AppServicePlan Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
AppServiceWebApp Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
ApplicationGateway Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
ApplicationInsights Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
ApplicationSecurityGroups Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
AutomationAccounts Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
AzureBastion Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
AzureDatabricks Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
AzureFirewall Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
AzureKubernetesServices Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
AzureSecurityCenter Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
CognitiveServices Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
ContainerRegistries Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
CosmosDB Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
DNS Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
DataFactories Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
EventGrid Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
EventHub Remove duplicate parameter (#150) 2019-10-17 10:18:53 -07:00
FunctionApps Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
InternetInformationServices Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
KeyVault Fixed defaultValue for secretsObject (#142) 2019-10-04 14:04:32 -07:00
KustoCluster BugFix Kusto Cluster docs (#149) 2019-10-10 00:30:10 -07:00
KustoDatabase Kusto Database Module (#148) 2019-10-10 00:28:16 -07:00
LoadBalancers Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
LogAnalytics Update GH actions to deploy shared services & tear down (#169) 2020-06-17 12:45:37 -04:00
LogicApps Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
MachineLearning Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
MachineLearningServices Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
MySQL Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
NISTControls Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
NetworkSecurityGroups Add sourceAddressPrefixes to the Resource section (#164) 2020-08-18 16:21:43 -07:00
NotificationHub Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
ProximityPlacementGroups Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
RecoveryServicesVaults Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
RedisCache Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
RouteTables Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
SQLDBServer Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
SQLDatabase Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
SQLManagedInstances Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
SQLServerAlwaysOn Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
SearchServices Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
ServiceBus Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
StorageAccounts Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
StreamAnalytics Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
UpdateAzureFirewall Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
VirtualMachineKeyEncryptionKey Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
VirtualMachineScaleSets Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
VirtualMachines Modified Shared Services environment & added new MS-VDI environment - In support for this new environment changes have been made to support all Azure environments (#163) 2020-04-30 09:37:04 -04:00
VirtualNetwork Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
VirtualNetworkGateway Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
VirtualNetworkGatewayConnection Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
VirtualNetworkPeering Module folder cleanup (#128) 2019-09-24 15:35:33 -07:00
VirtualNetworkPeeringCross Final Pull Request (#170) 2020-06-17 13:19:50 -04:00
WVDApplicationGroup Final Pull Request (#170) 2020-06-17 13:19:50 -04:00
WVDHostPool Final Pull Request (#170) 2020-06-17 13:19:50 -04:00
deploying-modules.md
module-readme-template.md
readme.md Final Pull Request (#170) 2020-06-17 13:19:50 -04:00
testing-modules.md

readme.md

Modules 2.0

A module is a reusable set of artifacts that can be composed into an archetype (environment). The modules can be deployed by anything that can deploy ARM templates. There is no need for a proprietary tool for deploying a single module. This document is about the 2.0 format for modules.

At a minimum, a module must have:

  • deployment and parameters files (e.g deploy.json and parameters.json)
  • a readme.md file
  • tests (e.g. module.tests.ps1) - located in the Tests subfolder

In addition, a module may include the following (each in a subfolder named after the asset type):

  • Policy (ARM template) definition + assignment
  • RBAC (ARM template) definition + assignment
  • Scripts (bash scripts, powershell, batch files, etc.)

Guidelines

A module usually represents a single resource or a set of closely related resources. For example, a storage account and the associated lock or virtual machine and network interfaces.

  • Don't use hyphens in file names, folder names, parameters, or variables.
  • Module names should use PascalCase and are derived from the names in the Azure Portal
  • Parameters and variables in ARM template should use camelCase
  • Don't use nested deployments pointing to different subscription and or resource group
    • There are situations where nested deployments are okay (i.e., BitLocker – to encrypt the OS drive youll need to run a nested deployment)

Testing

Tests rely on Powershell and Pester and on ARM validation.

There are two test files:

  • module.tests.ps1 is required.
  • output.tests.ps1 is optional. The optional file is for debugging purposes. It writes deployment input parameters to the console.

The module test verifies that required parameters are defined in the parameters file and verifies that the template file has the following parameters:

    $expectedProperties = '$schema',
    'contentVersion',
    'parameters',
    'variables',
    'resources',
    'outputs' | Sort-Object

Once all Pester test passes, proceed to run any of the following commands:

  • Powershell:

Test-AzResourceGroupDeployment

  • Azure CLI:

az group deployment validate

Before creating a PR, make sure that these two type of tests pass.