Thumbnail for null by null

11m 40s1,498 words~8 min read
Auto-Generated

[0:00]Hello, everyone. Thanks for tuning in to our webinar, Getting Started with Azure for .NET Developers. I'm your host, Jeff Fritz, and I'm joined today by our guest presenter, Laurent Bugnion. Laurent, it's great to have you. Thank you, Jeff. It's great to be here. So, today we're going to be talking all about how to get started with Azure. But before we dive into that, I want to talk a little bit about what we're going to cover and what to expect from today's presentation. First, we're going to show you how to set up your Azure account, if you don't already have one. Then we're going to dive into some of the core services that are most relevant to .NET developers, things like App Service, Azure Functions, and Azure SQL Database. We'll be building a small .NET application and deploying it to Azure, showing you the entire process from start to finish. So, by the end of this webinar, you should have a good understanding of how to get your .NET applications running on Azure. Before we proceed, a quick note about questions. Please feel free to ask questions throughout the presentation using the Q&A panel. We have a team of experts standing by to answer your questions in real time. And we'll also have a dedicated Q&A session at the end of the webinar to address some of the more common or interesting questions live. Alright, Laurent, are you ready to get started? Absolutely, Jeff. Let's do this. Excellent. So, the first thing we're going to do is talk about how to get an Azure account. If you don't already have one, you can sign up for a free Azure account, which gives you 12 months of free services and a $200 credit to explore Azure for 30 days. It's a great way to get started without any financial commitment. You can go to azure.microsoft.com/free to sign up. Once you have your account set up, you'll be able to access the Azure portal, which is your central hub for managing all your Azure resources. Now, let's talk about our sample application. We've built a simple to-do list application using ASP.NET Core. It has a web front-end and a back-end API. We'll be deploying the web front-end to Azure App Service and the back-end API as an Azure Function. For the data storage, we'll be using Azure SQL Database. First, let's create a new resource group in Azure. A resource group is a logical container for your Azure resources. It helps you manage and organize your resources. I'll open the Azure portal, go to resource groups, and click add. I'll give it a name, "DotNetWebinarRG," and choose a region. I'll choose East US. Next, let's create an Azure SQL Database. From the Azure portal, search for SQL databases and click Create. I'll select my subscription, my new resource group, and give the database a name. Let's call it "DotNetWebinarDB." We'll also need to create a new SQL server. I'll click "Create new" and give the server a name, a server admin login, and a password. Make sure to choose a strong password. For networking, I'll choose to allow Azure services and resources to access this server. This is important so our App Service and Function App can connect to the database. Now, let's configure the database settings. For our demo, a basic tier will be sufficient. I'll review and create the database. This might take a few minutes to deploy. While that's deploying, let's prepare our App Service. The Azure App Service is a fully managed platform for building, deploying, and scaling web apps. We'll be deploying our ASP.NET Core web front-end to App Service. From the Azure portal, search for App Services and click Create. Select your subscription and resource group, and give your app a name. I'll use "DotNetWebinarWebApp." For the runtime stack, choose .NET 6 (LTS). We'll choose Linux for the operating system and select a region. For the App Service Plan, we'll create a new one. An App Service Plan defines the underlying compute resources for your app. I'll call it "DotNetWebinarPlan" and choose the B1 (Basic) size for our demo. Review and create the App Service. This will also take a few moments to deploy. Now that our App Service is being created, let's switch over to Visual Studio. I have our to-do list application open here. First, we need to configure the database connection string. In the Azure portal, go to your SQL database and copy the connection string. In Visual Studio, open appsettings.json and paste the connection string into the "ConnectionStrings" section. Remember to replace `{your_password}` with the actual password you set for the SQL server. Next, let's publish the web application to Azure App Service. Right-click on your web project in Solution Explorer and select "Publish." Choose Azure as the target, then Azure App Service (Windows/Linux). Select your existing App Service instance, "DotNetWebinarWebApp," and click Finish. Visual Studio will create a publish profile. Click "Publish" to deploy your application. This process will compile your code, package it, and upload it to Azure. Once it's deployed, Visual Studio will open your application in the browser. You should now see your to-do list application running live on Azure. Now, let's talk about Azure Functions. Azure Functions is a serverless compute service that enables you to run event-triggered code without having to provision or manage infrastructure. We'll be deploying our back-end API as an Azure Function. From the Azure portal, search for Function Apps and click Create. Select your subscription and resource group, and give your function app a name. I'll use "DotNetWebinarFunctions." For the runtime stack, choose .NET 6 (LTS). Choose a region and a storage account. A storage account is required by Function Apps to manage triggers and logs. You can create a new one if you don't have an existing one. Review and create the Function App. This will also take a few moments to deploy. Once the Function App is deployed, we'll need to configure its connection string to the SQL database. In the Azure portal, navigate to your Function App, then go to "Configuration" under "Settings." Click "New application setting" and add a new setting named "SqlConnectionString." Paste your database connection string as the value, just like we did for the web app. Remember to update the password. Click OK and then Save. Now, let's publish our Azure Function project from Visual Studio. Right-click on your Function project in Solution Explorer and select "Publish." Choose Azure as the target, then Azure Function App. Select your existing Function App instance, "DotNetWebinarFunctions," and click Finish. Click "Publish" to deploy your Function App. Once deployed, your Function App will be live and ready to process requests. You can test it by navigating to the function URL in your browser or by using a tool like Postman. Great job, Laurent. We've successfully deployed a .NET web app and an Azure Function, both connected to an Azure SQL Database. This demonstrates a common architecture for many .NET applications on Azure. Now, let's take a look at some of the monitoring capabilities in Azure. Azure Monitor provides comprehensive solutions for collecting, analyzing, and acting on telemetry from your cloud and on-premises environments. For our App Service, you can go to "Application Insights" under "Monitoring" to see live metrics, performance, and error logs. Similarly, for Azure Functions, you can access monitoring data directly from the Function App blade. It provides insights into function executions, errors, and performance. We've covered a lot today, from setting up your Azure account to deploying a full-stack .NET application. Azure offers a vast array of services, and what we've shown today is just the tip of the iceberg. I encourage you all to explore further and experiment with different services. Thank you, Laurent, for that excellent presentation. Before we wrap up, let's address some of the questions from our audience. One common question is about cost management in Azure. Azure provides several tools to help you manage your costs, such as Azure Cost Management and Billing. You can set budgets, create alerts, and analyze your spending patterns. Another question is about scaling your applications. Azure App Service and Function Apps offer robust scaling capabilities. You can configure auto-scaling rules based on metrics like CPU usage or request count. This ensures your application can handle varying loads efficiently. Finally, many of you asked about deployment options. Besides Visual Studio, Azure supports various deployment methods, including Git integration, Azure DevOps, and continuous deployment from GitHub. This allows for flexible and automated deployment pipelines. That brings us to the end of our webinar. I want to thank Laurent again for sharing his expertise and all of you for joining us today. We hope this session has been informative and helps you get started with Azure for your .NET applications. Don't forget to check out the resources section for links to documentation, free Azure accounts, and more. Have a great day, everyone!

Need another transcript?

Paste any YouTube URL to get a clean transcript in seconds.

Get a Transcript