With my use of scripting and Azure Cloud Shell, I’m automating and building my environment, including SQL Database resources and then have a requirement to access and build the logical objects. This means that I need a firewall rule build for the Azure Cloud Shell I’m working from. The IP for this cloud shell is unique to the session I’m running at that moment.
The requirement to add this enhancement to my script is:
-
Capture and read the IP Address for the Azure Cloud shell session.
-
Populate the IP Address to a Firewall rule
-
Log into the new SQL Server database that was created as part of the bash script and then execute SQL scripts.
Click through for instructions.