Azure Bastion for Hybrid Cloud Environment - azure

Is there any way to use Azure Bastion to connect to on-prem systems as well as Azure virtual machines?
I have a hybrid cloud environment where some key machines are on-prem and some are Azure VMs. The Azure VNet is extended with a VPN tunnel so the azure VMs can talk to the on-prem machines.
In Googling my question, I was not able to find much...
The official page for Azure Bastion describes it as '''Azure Bastion is provisioned directly in your Virtual Network (VNet) and supports all VMs in your Virtual Network (VNet)'''
This page talks about hybrid envrionments https://blog.ahasayen.com/introducing-azure-bastion/ , saying:
'''You might also have some sort of hybrid connectivity with your on-premises network and when you are outside the office, you use point to site VPN to securely access your VNET, which is the ideal situation.'"
I am aware of Azure Arc which is currently in preview. Would something like that be appropriate to make this work?
My overall questions are:
Am I totally barking up the wrong tree here? Is my understanding off?
Is it possible to use Azure Bastion to access an on-prem server on an extended VNet?
Thanks in advance!

As far as I know, currently, it's not possible to use Azure Bastion to access an on-prem server on an extended VNet. You only could use Azure Bastion to access all the VMs in the VNet which has AzureBastionSubnet. Refer to this blog
Azure Bastion resides on the same virtual network (VNet) as the
servers accessed and only connects to one VNet.
Actually, you can have a private and securely RDP/SSH connection between your on-premise server and Azure VM via a VPN gateway, you just can not RDP/SSH on-premise server via Azure portal. If you need this feature with Azure Bastion, it's welcome to give feedback or upvote these similar feedback1 and feedback2.
Hope this could help you.

This is now possible via the new capabilities introduced in Azure Bastion Standard Tier.
https://learn.microsoft.com/en-us/azure/bastion/connect-ip-address

Related

Create a simple VPN in Azure

TLDR;
I got Azure credits, how do I make a simple VPN?
I recently got some Azure credits through a hackathon. How do I create a simple VPN on Azure. It need not be too feature rich, I just wanna use it to access blocked or region specific websites.
I saw on Azure portal that there is virtual machine and virtual network. I don't exactly need a VM, just want to redirect all network traffic through the virtual network.
How do I do this in Azure, Has anyone done anything similar in Azure?
Free VPN are slow and have bugs and paid VPN are expensive & I would like to use my azure credits to create my own VPN.
It sounds like you want to use Azure VPN similar to a consumer VPN like ExpressVPN or NordVPN which protects your client while you surf the Internet. Azure VPN is not designed to be used to surf the Internet. Azure VPN is a service that allows you to create a secure Site-to-Site or Point-to-Site VPN into an Azure Vnet. This allows you to communicate securely with resources in Azure without exposing them with a Public IP.
A VPN gateway is a specific type of virtual network gateway that is used to send encrypted traffic between an Azure virtual network and an on-premises location over the public Internet. You can also use a VPN gateway to send encrypted traffic between Azure virtual networks over the Microsoft network

Can Azure App Services have fixed MAC addresses?

I've got an Azure app service that I'd like to use to run some software that requires licensing. The license is provided via a server on our internal network. The issue being finding a way to connect to this server.
The first option is to provide a fixed license that ties to the MAC address. However I don't think this will be possible from an app service, as it does not really have a MAC address? Can I provide a VNI to it and obtain a fixed MAC address that way?
What other options are there? Can the app service be tied to a VNET that can tunnel to the on-premises resource? Should I use a VM with a VNI instead of an app service? Any resources on these kind of problems would be appreciated.
I have used Azure Relay to connect my on-prem service with my app service. Not sure if you have already considered this option.
If your requirement is to establish a connection between your on-prem service and you app service, check out this https://learn.microsoft.com/en-us/azure/service-bus-relay/relay-what-is-it
Hope this helps
You could use VNet Integration with Azure App service and Azure VPN gateway to connect to on-premise resources. VNet Integration is used only to make outbound calls from your app into your VNet. There are Regional VNet Integration and Gateway-required VNet Integration.
How regional VNet Integration works
Regional VNet Integration works by mounting virtual interfaces with
addresses in the delegated subnet. Because the from address is in your
VNet, it can access most things in or through your VNet like a VM in
your VNet would. The networking implementation is different than
running a VM in your VNet. That's why some networking features aren't
yet available for this feature.
How gateway-required VNet Integration works
Gateway-required VNet Integration is built on top of point-to-site VPN
technology. Point-to-site VPNs limit network access to the virtual
machine that hosts the app. Apps are restricted to send traffic out to
the internet only through Hybrid Connections or through VNet
Integration. When your app is configured with the portal to use
gateway-required VNet Integration, a complex negotiation is managed on
your behalf to create and assign certificates on the gateway and the
application side. The result is that the workers used to host your
apps are able to directly connect to the virtual network gateway in
the selected VNet.
For more information, you could read this blog---How to Connect Azure Web Apps To On-Premises
In addition, If you need more control of the application deployment and less scale out or in than the Azure app service. You could host your application on the Azure VM, then set up a VPN gateway in that VNet where Azure VM locate, it allows access to the on-premise resources from your Azure VM as usual in the internal network.

Connect Azure Cloud Service in Virtual Network to Azure SQL database

I have an Azure Cloud Service (Worker Role) that needs to connect to my Azure SQL database and also connect to an external database.
In development the external database was on the public Internet and connectivity was not a problem.
However, the solution now needs to be deployed in a production environment and access to the external database is to be restricted by setting up a Virtual Network.
The Cloud Service, when deployed in the Virtual Network, gets an IP from the subnet, but seems to become inaccessible to the outside world, and is not connecting to the Azure SQL database (I also cannot RDP to it).
This seems to be beyond my level of understanding of networking, but I don't see why it should lose access to its neighbours in the Azure environment.
What am I missing? Do I need to get involved with Endpoints? Is the Virtual Network misconfigured?
Thanks in advance.
Your question is quite vague, in terms that it does describe the whole picture in the best possible way. Let me put my answer based on my understanding about your issue.
First of all - Azure virtual Network is Virtual Network. It is designed to enable secure cross-premisses connectivity with Windows Azure Data Center.
When you deploy a proper PaaS Cloud Service (Worker Role / Web Role) in a Virtual Network, the role instances get IP Addresses allocated from the defined DHCP pool (the VNet Definition).
When you deploy any service in an Azure Virtual Network you have to take care of Name Resolution! Meaning that, if you do not provide a proper DNS Server, your cloud instances will not be able to resolve any address. That includes Azure SQL Database servers. More on Name Resolution can be read here.
Next, but not less important - Azure SQL Database servers are not part of, and, as of March'2013, cannot be added to Azure Virtual Network!
The last statement means that in order for your Worker Role to access Azre SQL Database server, you need to provide a proper DNS server in your Azure Virtual Network.
And lastly, when you deploy a PaaS service into a Virtual Network, in order to access it via Remote Desktop need to:
* Properly enable and configure RDP extension. it will anyway create Input Endpoint. But this is the only way to enable RDP on PaaS right now;
* You could probably enable RDP via PowerShell startup script and access RDP via the VPN tunnel for the Virtual Network - say you configured a Site-to-Site or Point-to-site VPN for your Azure VNet.
Check the building cross-premises Virtual Network guide here.

Connecting to an Azure Virtual Network from PC

We have a Virtual Network of VMs, storage accounts and websites hosted and working together in the Azure cloud.
Is it possible to connect my work/home PC to this Virtual Network using some VPN software?
Generally speaking two options exist, you can read about these here -
Windows Azure Connect let's you configure machine-to-machine VPN and is agent based
Configuring a private network let's you create a site-to-site VPN, but it typically requires a VPN appliance. I've seen posts on the internet about people managing to configure their router as the VPN gateway but, at least at this point, this is not easy nor supported.
Also worth reading is this overview of Windows Azure Networking features that covers both (and Traffic Manager) by David Chappel
have a look at using Azure Virtual Networks in conjunction with Azure Virtual Machines: http://www.windowsazure.com/en-us/manage/services/networking/add-a-vm-to-a-virtual-network/

How to Connect Azure Worker/Web role to Azure Iaas VMs without using public IP's?

We want to run MongoDB and some custom services on Azure Iaas VMs and connect to them with our roles but we do not want to have public IP exposure on the VMs.
If possible what is the best way of doing this?
If not possible is this on the roadmap?
We can add the VM's under the same cloud service and they can communicate happily, the roles are in same deployment so they communicate, but issue between the vm's and roles. We appreciate that the Iaas stuff is still in preview.
Thanks
If you have your Windows Azure Web/Worker Role and Windows Azure Virtual Machine in the same DC you can access them directly using internal IP address using Virtual Networking (Vnet) using internal Endpoints. To achieve it first you would need to create a Virtual Network and then add your Virtual Machine to this VNet. VNet will give your internal IP address and your Web/Worker Role can communicate to this internal IP address.
You can not do mix mode deployment directly from Windows Azure Preview Portal (it is not supported in preview yet) however you can use PowerShell VNet cmdlets to get it configured and working. To need further assistance with VNet team you can contact them directly here.

Resources