Creating Your First Service


Course Introduction
Course Conclusion

The course is part of these learning paths

AZ-900 Exam Preparation: Microsoft Azure Fundamentals
course-steps 9 certification 1 lab-steps 3
Getting Started with Azure
course-steps 2 certification 1
3 Pillars of the Azure Cloud
course-steps 4 certification 4 lab-steps 1
Introduction to the TOP Public Cloud Platforms
course-steps 3 certification 1
more_horiz See 1 more
Start course
star star star star star-half


Azure is Microsoft’s Cloud Computing platform. It is an amalgamation of services for creating, deploying and managing applications that run in Microsoft’s secure worldwide data centers. The set of services can make virtually any software solution possible, from large retail targeting a global audience to CPU-intensive, scientific data calculations, to simple data backups. Almost any software that can be imagined can be written to take advantage of Azure services and can run in the Microsoft Cloud.

In this course, we will review the categories of services available in Azure today, then select some of the more commonly used services for a closer look. We will wrap up with a conceptual overview of how we can combine many Azure services to build a more ambitious solution. By the end of the course, you should have a general appreciation for the breadth of available services and start to see how they can be composed to create more powerful business solutions.

This course is for developers, operations engineers, and other IT professionals. Viewers should have a basic understanding of the cloud and cloud terminology.

The Learning Objectives for the course are:

● Learn what categories of Azure services exist and what problems they address.

● Learn the most common Azure services and how to use them now.

● Learn how you can combine Azure services.

Lessons Include:

Welcome and Introduction: These brief lectures will introduce you to the instructor and let you know what you'll be covering.

Azure Services: A description of how to build your first service.

Service Catagories: Overview of the 14 categories of Azure Services

Services Drill Down: A look at Websites, SQL Database, and Storage

Managing Services: This lesson includes a Security Center demo and a Command Line Interface demo.

Putting it Together: Tying all that you've learned into some real-life examples.

Conclusion: A wrap-up of what you've learned.




The easiest way to get started creating and managing Azure services is through the Microsoft Azure portal, at So that's where we'll begin, starting in a newly-created Azure subscription for a fictional Azure bookstore company.

This is the Microsoft Azure portal. Let's take a moment to point out a couple of the important features. The list on the left helps you find instances of the services you've already created, organized by service type. For example, resource groups, app services, and SQL databases.

The main area to the right is your operational dashboard. You'll notice there's one widget that lists all of the resources we've created so far, across all service types. And as you can see, that list is empty right now, since we have not created any services yet in this Azure subscription.

This is a new subscription. Below the All resources widget, you'll see a Service health widget, with a map of the world. On that map of the world, you'll see a bunch of green circles with check marks. Each of those circles represents a region of the world where the Azure data center services are available. The fact that it's a check mark, and it's a green circle, tells us that services are all running properly, so this tells us that, globally, everything is fine with the Azure platform. But furthermore, it gives you an idea of the distribution of Azure data centers around the world, so you can have an idea of all the places where you might be able to deploy Azure to be closer to your customer base.

Infrastructure as a Service, or IaaS, is one popular way to use public cloud platforms. So let's use the portal to create our first Azure service instance, an IaaS Linux virtual machine running a MySQL database. Let's glance in the Virtual machines category and see there are no existing VMs in here. This is expected. Let's exit this blade and create one.

I'm gonna click on New to create a new service. This box allows us to search through the entire Azure marketplace. This spans all service categories, and includes both first-party and third-party offerings. Within virtual machines, first-party images are those offered directly from Microsoft, while other companies offer the third-party images. By typing in mysql, we can see all the matching choices, all of which appear to be third-party images.

Let's click on the first entry to see more details. In the description, it's clear that this is a pre-configured virtual machine image from Bitnami that has MySQL installed on Ubuntu Linux. That means this is an example of a third-party VM offering, with Bitnami being the provider, not Microsoft. This VM fits our needs, so we'll choose this image. I'll click Create and step through the wizard. And we give our virtual machine a name. Call it mysqlvm. Just to show that we can make some choices here, I'm gonna switch from a solid-state drive to a hard disk drive. We provide a username.

This is the username to log in to the Linux VM. We'll call it linuxuser. Normally, we'd use an SSH public key, but since this is just a demo, I'm gonna switch to password. Create a new resource group. We'll call it mysqlvm resource group, just to keep it simple. And click OK.

You see here the different virtual machine size offerings. An A1 Standard comes with one core, one CPU core, and 1 3/4 gigabytes of RAM, two data disks, and so forth. You can see the rest here. And this costs $44.64 per month. For roughly twice as much money, you get roughly twice as much machine when you go up to the A2, with two cores, twice as much memory, twice as much disk, and so forth. And that proceeds further.

There are other options, if we choose View all, but we're just gonna stick with a very simple solution here. We're gonna choose A1 Standard, select, and go on to the next step. We're gonna take all the defaults here, and go on to the next step. Here's a summary of what we're about to create. Looks good, so I'll click OK here. And here's the final confirmation, so we know how much we're paying for what we're buying. And before we click Purchase here, we're told exactly what we're paying for.

There's two parts to the purchase price. One is the third party, and one is Microsoft. As you can see at the top there, the MySQL price from Bitnami is zero, so there's no upcharge there. And the charge from Microsoft for the A1 sized virtual machine is six cents per hour, in US dollars. Click Purchase, and our virtual machine is being created. It took Azure a few minutes to spin up our Linux VM with MySQL running on it. But as you can see, the Azure portal now knows about our new Linux VM. And we see it listed in the All resources. It's this mysqlvm. And if we run into the Virtual machines category here, we also see our mysqlvm. Let's go in and have a look.

There's a full monitoring and management experience available here through the portal. For example, we could go to the Size option. And we can make the virtual machine larger or smaller depending on our needs. We'll cancel out of that, however. Right now, let's focus on using the portal to figure out what our virtual machine's IP address is, so that we can remote into it using SSH. The IP address is here, and just so you know, if you don't wanna refer to it by its IP address, you can also configure a DNS name, and then the DNS name would be

We're not gonna bother to do that here, so we'll just close this blade. And we'll actually use this helpful Connect popup for the exact command we need to log in with SSH. Copy that to the clipboard, and we'll go over to a Mac terminal window. So we'll paste the results into our terminal window. We use the command we got from the portal here. And we're in.

So I've logged in using the username and password I provided in the portal, while creating this VM, and as you can see, if you look around, this is your Linux box. You have full control. You have root access. There was a MySQL database included with the VM image we selected. It wasn't just a baseline Linux box. It was Linux plus MySQL. Let's use the uncomplicated firewall to show that there is a MySQL process listening for connections. Error, you need to be root to run this script. Of course, since we are root, we can do it.

As you can see, there's a TCP connection allowed on port 22 for SSH. That's how we're logged in currently. As you can also see, there's a MySQL daemon listening on port 3306. That's how we'll later be able to connect to the MySQL database using MySQL Workbench. In a real scenario, you'd likely create new Linux and MySQL users for remote access, you might lock down your firewall, and do other things. But since this isn't intended to be a Linux or MySQL tutorial, we'll stick to the default configuration.

We'd like to keep the focus on showing how easy it is to create Infrastructure as a Service VMs with Azure. So let's quickly switch gears again and take the IP address we used for SSH and use it with MySQL Workbench to connect to the MySQL database already running on this VM. As you can see, I've partially configured a new connection to the MySQL database, with the same IP address used to SSH. I'm gonna hit Test Connection, and it's gonna ask me for a password. But when we created the virtual machine through the portal, it didn't ask us to provide a MySQL password.

It turns out that the MySQL password is generated for us, and we're gonna go back to the Azure portal and retrieve it. Here we are in the Azure portal. We're gonna click Diagnose and solve problems. And this is gonna bring up several options. The most important one for us here is to view boot diagnostics. This shows a stream of log messages that are generated during boot time. And we're gonna scroll down. And on line 890, we find our password. This password should only be available after the first boot, so you need to go retrieve it and save it. And we've copied it to the clipboard here, and we'll go back over to MySQL Workbench.

I'm gonna hit Test Connection again, paste in the password, and hit OK. Successfully made the MySQL connection, great. So we're gonna go ahead and connect. Now that we're in, let's create a very simple database with a simple bookstore schema. And you can see we've created a database. We've created a books table, trivially. We've inserted two rows into it. And we've viewed the rows here. And the first row is Bill's Cloud Architecture Patterns book. And the second row is Robin and Mike's Microsoft Azure Essentials book. So this is simply to show that you have a MySQL database running.

It's a real database, it works. The MySQL tools that you're used to using, such as MySQL Workbench, all still work, as expected. And we'll actually come back to this database later, and we'll use it in another example in another lecture. Let's jump back to the portal now. So back here in the portal, we have our All resources listing the mysqlvm that we created, the Ubuntu Linux VM with MySQL running on it, but we've also got a few other resources that we've created. We have an IP address, a network interface, a storage account for diagnostics, a storage account to back a hard disk, a network security group, and a virtual network.

About the Author

Bill Wilder is a hands-on architect currently focused on building cloud-native solutions on the Microsoft Azure cloud platform. Bill is CTO at Finomial which provides SaaS solutions to the global hedge fund industry from the cloud, co-founded Development Partners Software in 1999, and has broad industry experience with companies of all sizes – from modest startups to giant enterprises. Bill has been leading the Boston Azure group since founding it in 2009, has been recognized as a Microsoft MVP for Azure since 2010, and is author of Cloud Architecture Patterns (O’Reilly Media, 2012). He speaks frequently at community events, and occasionally at conferences, usually on topics relating to cloud, cybersecurity, and software architecture.