Giter Club home page Giter Club logo

vwan-playground's Introduction

Azure Virtual WAN Playground

Welcome to the Azure Virtual WAN Playground repository! Your one-stop shop for an awesome Azure Virtual WAN lab environment.

What is Azure Virtual WAN Playground?

This repo is dedicated for all poor souls out there who wants to play around with Azure Virtual WAN but don't have unlimited Azure Credit in their subscriptions (most of us 😊). I've put together a template that deploys Azure Virtual WAN and all resources needed to play around with the service and test everything from Site-to-Site VPN, Point-to-Site VPN, Routing, Secured Virtual Hub (Azure Firewall), Virtual Network connections and more. The goal is to make it easy and fast to spin up an environment when you need to test a feature for a short period of time and then remove it all when finished.

How it's built

The Azure Virtual WAN Playground is built using πŸ’ͺBicep. It consists of multiple module templates, some config files and a main template that puts everything together.

Deployment

The template is built using the target scope subscription. To deploy the playground create a new subscription deployment using your favorite Azure command line tool and sit back and relax.

Pre-reqs

Before you deploy the VWAN Playground there are some prerequisites that you need to look into.

Config file

The template is dynamic and will deploy different environments depending on which config file is being used for your deployment. Available configs are:

Organization Config file Description
Contoso contoso.json Multiple Virtual WAN hubs in different regions, landing zones and "on-premises" VNets. P2S VPN, S2S VPN, Azure Firewall.

Additional configs are in the works. Planning to add some configs with single regions VWAN hubs.

Decide which config you want to use and update the main.bicep template to use the config file.

// Load VWAN Playground Config file. 
var vwanConfig = json(loadTextContent('./configs/contoso.json'))

P2S Config

Before you deploy the template, make sure that you add values to the p2sVpnAADAuth.json for a successful Point-to-Site VPN deployment. The application ID for the Azure VPN Enterprise Application and your Tenant ID is needed to configure VPN Auth. More info about the config files can be found here.

Bicep

The Playground is built and tested using Bicep v0.4.1124, make sure that you have this or a newer version installed before starting the deployment (or build the Bicep file to an ARM template).

Check installed Bicep version using Bicep CLI (will be used by Azure PowerShell module):

bicep --version

Check installed version of Bicep CLI used by Azure CLI:

az bicep version

Create the deployment

Create the deployment using your preferred command line tool.

NOTE: The deployment is complex and consist of multiple resources that takes a long time to provision. Expected deployment time is over 1 hour.

PowerShell

$params=@{
    Name = 'vwan-playground'
    Location = 'westeurope '
    TemplateFile = '.\playground\main.bicep'
}
New-AzSubscriptionDeployment @params

Azure CLI

az deployment sub create --name vwan-playground --location westeurope --template-file .\playground\main.bicep

Topologies

The Azure Virtual WAN Playground deploys the following topologies:

Contoso

FAQ

Can I connect to the servers in the "landing zones" and "On-Premises"?

Yes, there is a Bastion host deployed in the <nameprefix>-sharedservices-rg resource group. The Bastion VNet is peered with all VNets in the deployment to allow RDP connection via Bastion.

Does name resolution work between VMs?

Yes, there is a Private DNS zone <nameprefix>.com that is linked to all VNets and auto registration is enabled.

Traffic between VMs in Firewall enabled regions are not working, why?

Azure Firewall is blocking all traffic by default. You need to create Firewall rules to allow traffic between "landing zones" and "on-premises".

Will you provide additional sample configurations?

No, but you can make your own by modifying the existing config files.

Contributing

If you find this project interesting and want to contribute, please feel free to open issues with feature requests or open a pull request with suggested improvements.

vwan-playground's People

Contributors

egullbrandsson avatar johnwildes avatar palmemanuel avatar stefanivemo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

vwan-playground's Issues

Create a new playground config with single VWAN hub

Is your feature request related to a problem? Please describe.
The contoso config is huge. Create a more simple single region config.

Describe the solution you'd like
Remove north europe and east us regions from contoso config.

Issue with "None" route table

Describe the bug
First, thanks a lot for this repo. I use it as inspiration.
To compare my setup with this setup, I wanted to deploy this repo as is to an Azure subscription.
However, my deployment fails with the following error on the deployment of weu-lz1-vnet-conn-deploy:

"message": "The specified propagated route table '/subscriptions/REDACTED/resourceGroups/andtest-vwan-rg/providers/Microsoft.Network/virtualHubs/andtest-vwan-westeurope-vhub/hubRouteTables/None' for connection '/subscriptions/REDACTED/resourceGroups/andtest-vwan-rg/providers/Microsoft.Network/virtualHubs/andtest-vwan-westeurope-vhub/hubVirtualNetworkConnections/peeredTo-weu-lz1-vnet' is invalid 'Please retry another PUT on the propagated route table to populate Nrp Uri Mapping entity for route table.'.",

To Reproduce

  1. Clone repo
  2. Select subscription with az account set
  3. Run az deployment sub create -l westeurope --template-file .\playground\main.bicep
  4. See error

Additional context
I changed contoso to andtest in the config and populated the fields in p2sVpnAADAuth.json. Nothing else.

PS C:> az version      
{
  "azure-cli": "2.45.0",
  "azure-cli-core": "2.45.0",
  "azure-cli-telemetry": "1.0.8",
  "extensions": {
    "alias": "0.5.2",
    "application-insights": "0.1.18",
    "azure-devops": "0.26.0",
    "logic": "0.1.6",
    "virtual-wan": "0.2.15"
  }
}
PS C:> az bicep version
Bicep CLI version 0.14.46 (ef2ceb1a0e)

Add option to autogenerate VM password and PSK

Is your feature request related to a problem? Please describe.
At the moment the VM Password and PSK must be provided during deployment.

Describe the solution you'd like
If no value is passed to the parameters vmAdminPassword and psk I would like to have them generated and saved to a Key Vault in the shared services resource group.

Additional context
Possible solution:

  • Add a Key Vault to the shared services resource group
  • If no value is provided to the parameters generate a VM admin password and PSK. Does not have to be fancy since it's just a lab environment.
  • Store password as secrets in the Key Vault.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.