<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Stefan Acimovic on Medium]]></title>
        <description><![CDATA[Stories by Stefan Acimovic on Medium]]></description>
        <link>https://medium.com/@stefanacimovicMEng?source=rss-9b2812726c80------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*03goa61xK77CQ9Hq1w4qoA.jpeg</url>
            <title>Stories by Stefan Acimovic on Medium</title>
            <link>https://medium.com/@stefanacimovicMEng?source=rss-9b2812726c80------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 09:31:59 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@stefanacimovicMEng/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Write your own code coverage script for your .NET projects]]></title>
            <link>https://medium.com/@stefanacimovicMEng/write-your-own-code-coverage-script-for-your-net-projects-e26b621aa0dc?source=rss-9b2812726c80------2</link>
            <guid isPermaLink="false">https://medium.com/p/e26b621aa0dc</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[dotnet]]></category>
            <category><![CDATA[dot-net-developers]]></category>
            <dc:creator><![CDATA[Stefan Acimovic]]></dc:creator>
            <pubDate>Wed, 19 Oct 2022 10:08:21 GMT</pubDate>
            <atom:updated>2022-10-19T10:08:21.804Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to create code coverage script for your .NET projects</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*bzBzLaqly2IakKP9" /></figure><p>Whether your client requires you to keep code coverage above a certain percentage or you just want your code to be future-proof, good code coverage is one of the nice things to have in your project.</p><p>Not every IDE supports code coverage checking by default (looking at you VS) or if it supports then you have to pay for it (looking at you Rider). The good thing is that for VS there is a couple of free plugins that are available for checking your code coverage (my recommendation is <a href="https://marketplace.visualstudio.com/items?itemName=FortuneNgwenya.FineCodeCoverage"><strong><em>Fine Code Coverage</em></strong></a>). Still, if you are using Rider, well, you can pay for JetBrains plugin <a href="https://www.jetbrains.com/dotcover/"><strong><em>dotCover</em></strong></a> or you can follow this post and create your code coverage script for free!</p><p>If you follow this post in the end you will have your custom code coverage script that you can even use in your CI/CD as one of the steps in the pipeline that will check if your code is covered above some percentage and you can set pipeline to fail if that’s not the case!</p><p>So let’s get started!</p><p>First, we need to install an open-source tool called <a href="https://github.com/coverlet-coverage/coverlet"><strong><em>coverlet</em></strong></a><strong><em>. </em></strong>Coverlet is a cross-platform code coverage framework for .NET, with support for the line, branch, and method coverage. It works with .NET Framework on Windows and .NET Core on all supported platforms.</p><p>Run dotnet tool command in CMD or PowerShell:</p><pre>dotnet tool install --g coverlet.console</pre><p>This will install coverlet as a global tool and now we can use its commands. Then navigate to your test project folder and run:</p><pre>coverlet /path/to/test-assembly.dll -t &quot;dotnet&quot; -a &quot;test --no-build&quot;</pre><p>Let&#39;s explain this command. Of course, we start with the <em>coverlet</em> keyword (if you type <em>coverlet </em>you can find all options that can be used), followed up with the relative path to your test project .dll file (note that this is the path to your <strong>Test </strong>project .dll). Next, we specify the path to the test runner application using —-target or -t , and in our case, it’s dotnet. This is followed by the arguments that will be passed to the test runner using the parameter --targetargs or -a and we pass test --no-build (no build is provided so that dotnet build is not executed but then you will need to be sure that your test-assembly.dll exists, in other words, run dotnet build before this :).</p><p>Now run it and you should get something like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eiIps7-oYqCHFwLiBtr2lA.png" /><figcaption>Result of coverlet command</figcaption></figure><p>And like that, you get code coverage for your project. As I mentioned before, you get Line, Branch, and Method code coverage for each module and also as calculated total and average code coverage.</p><p>But something I need to add. My example is just a simple project with one service and it’s not near a real project. In real projects, we have a lot more projects for different uses that in this case will for sure show wrong code coverage! For example, why should <em>Program.cs</em> be counted in our code coverage, I mean it can, but should it? So an additional option that we should use is--exclude that can be used to filter expressions to exclude specific modules and types. It uses some specific patterns for excluding that you can find <a href="https://github.com/coverlet-coverage/coverlet/blob/master/Documentation/MSBuildIntegration.md#filters"><strong><em>here</em></strong></a>.</p><p>Let’s add one additional service that affects our code coverage but it should be excluded.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cOS5yPW8cI2gdmVFcvdboQ.png" /><figcaption>Code coverage affected by service that should be excluded</figcaption></figure><p>As you can see our total and average code coverage dropped because of the new service. And now let’s upgrade our script to exclude this service:</p><pre>coverlet /path/to/test-assembly.dll -t &quot;dotnet&quot; -a &quot;test --no-build&quot; --exclude &quot;something to exclude&quot;</pre><p>And now code coverage for my example is:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fL1J6MTLkwpWSiZILKTELA.png" /><figcaption>Code coverage after service has been excluded</figcaption></figure><p>As you can see now, excluded service says it has 100% code coverage and now we get the correct total code coverage that doesn’t consider that excluded service, but as you can see the average does.</p><p>Okay, we now have code coverage in numbers but would it be nice to also see what is covered and what&#39;s not? Of course, it would! We just need to use something to generate a code coverage report and something to read that report and visually show it.</p><p>To generate a code coverage report we have to install the <em>Coverlet </em>Nuget package <a href="https://www.nuget.org/packages/coverlet.collector"><strong><em>coverlet.collector</em></strong></a><strong><em> </em></strong>to our test project. After that, we can just use the dotnet test command to create a code coverage report (note this will generate the report in your test project folder and if you want to save it somewhere else you can just use --results-directory option and just provide the path where you want to save it):</p><pre>dotnet test --collect:&quot;XPlat Code Coverage&quot; </pre><p>This will generate a TestResult folder with a .xml file that is our code coverage report:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rLZQxDpRHjLhtN74JjM_fA.png" /><figcaption>Generated code coverage report</figcaption></figure><p>In the background <em>Coverlet </em>uses <a href="https://cobertura.github.io/cobertura/"><strong><em>cobertura</em></strong></a>. And it generates a report that you can try to read but it’s not really for us, but for a tool that uses that file to show this report visually.</p><p>Now we have a code coverage report and we need something to visualize it. For this, we are going to use a dotnet tool called <a href="https://www.nuget.org/packages/dotnet-reportgenerator-globaltool"><strong><em>dotnet-reportgenerator</em></strong></a>. We are going to install it like in the first step we did with the coverlet.</p><pre>dotnet tool install -g dotnet-reportgenerator-globaltool</pre><p>Now we can use this tool with keyword <strong><em>reportgenerator</em></strong><em>. </em>And now we run its command:</p><pre>reportgenerator -reports:”.\coverage.cobertura.xml”<br>-targetdir:”coverageresults” -reporttypes:Html</pre><p>Let’s quickly explain this command. As you can see first we need to provide a relative path to the <em>cobertura </em>report .xml<em> </em>file and provide a target dir where we want to save files that are going to be generated by <em>reportgenerator</em>. In the end, we provide which report type will be used and we will specify HTML (more options can be found on their <a href="https://github.com/danielpalme/ReportGenerator"><strong><em>GitHub</em></strong></a>). This command also accepts excluding some files that we don’t want to include in our code coverage. This can be done with-filefilters option and then we specify what pattern we want to exclude (again you can find more on their GitHub).</p><p>And after you run this command you will get a new folder with all required HTML files:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/478/1*h_9_tyWyPdfgEIJAIVqbmg.png" /><figcaption>New generated folder with all required files for visualization of the report</figcaption></figure><p>And if you start <em>index.html</em>, you will get something like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8l9ad98E8CRSM3DhNpf01A.png" /><figcaption>Visualized code coverage report using reportgenerator tool</figcaption></figure><p>And if you click on any service you can have a detailed view of what is covered and what’s not:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lBlABGeT-f6FcqFwnqKaNw.png" /><figcaption>Detailed view of service coverage</figcaption></figure><p>And here you go! Your own fully visual code coverage! 🎉</p><p>We all know that we don&#39;t want to type all these commands every time we want to check what’s our project code coverage. So I got you covered (pun not intended :)!</p><p>Here is the <em>PowerShell </em>script that I&#39;m currently using for my projects. This could also be the <strong>TL;DR</strong> part of this post for everyone who doesn’t want to read the rest of the post, but I think this is the better way to generate code coverage for your project by yourself.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7140b86de2f3489bb14c2b3b9e0a3861/href">https://medium.com/media/7140b86de2f3489bb14c2b3b9e0a3861/href</a></iframe><p>As you can see you just need to call this script with one required parameter and that’s an absolute path to your test project .dll file and one more optional parameter and that’s excluded files pattern that will, as you noticed before, exclude files with that pattern from code coverage. I’ve set that code coverage reports are saved on the desktop but you can change it however you want (you can add a parameter for that). And when the script is finished it will automatically open the <em>index.html</em> file and show the code coverage report for your project!</p><p>So that’s it, guys! This is the end of the post! If you’ve read the whole post awesome and give yourself a clap! Hopefully, you learned something today, and this can maybe help you in the future if you don’t have some code coverage tool (I hope you don&#39;t get into that situation :). You need to know that this is not rocket science and as you can see, you just need a couple of tools to do this yourself.</p><p>Guys, if you liked this post feel free to follow me for more stuff like this in the .NET world! And don’t hesitate to post any questions or suggestions, I will be more than happy to answer them :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e26b621aa0dc" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Deploy .NET 6 Web API to Azure with GitLab CI/CD]]></title>
            <link>https://medium.com/@stefanacimovicMEng/deploy-net-6-web-api-to-azure-with-gitlab-ci-cd-b1e28e6b13dc?source=rss-9b2812726c80------2</link>
            <guid isPermaLink="false">https://medium.com/p/b1e28e6b13dc</guid>
            <category><![CDATA[azure]]></category>
            <category><![CDATA[gitlab-ci]]></category>
            <category><![CDATA[dotnet-core]]></category>
            <dc:creator><![CDATA[Stefan Acimovic]]></dc:creator>
            <pubDate>Fri, 06 May 2022 23:47:27 GMT</pubDate>
            <atom:updated>2022-05-07T15:11:58.384Z</atom:updated>
            <content:encoded><![CDATA[<h3>Deploy .NET 6 Web API to Azure with GitLab CI/CD</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5RB35CPz0dhD-q_xp6wYNQ.png" /></figure><p>Hi guys,</p><p>I recently had a task to publish and deploy our .NET 6 Web API to Azure with GitLab CI/CD and I was quite annoyed that I couldn’t find any real example of how to do it. Yes, I could find how to publish and deploy .NET Web API using Azure DevOps CI/CD but of course there is nothing on how to do it in GitLab!</p><p>So I decided to write that example and maybe help someone that has the same task as me (maybe that will be me again in future) :)</p><p><strong><em>Notice:</em></strong> This will not be ‘Learn GitLab CI/CD from scratch’ nor ‘Learn Azure from scratch’. You will need at least some basic knowledge of these two topics so that you can easily follow this example.</p><p>Let’s go…</p><h3><strong>Prerequisite:</strong></h3><p>Before we start, you will need to:</p><ul><li>Create required resources in your Azure project (for test, you can just create ‘<em>Resource group</em>’ and ‘<em>App service</em>’ resources). <br><strong><em>Notice</em></strong>: Just check in your ‘<em>App service</em>’ configuration that you’ve selected ‘<em>Stack</em>’ to be .Net, ‘<em>Major</em>’ and ‘<em>Minor</em>’ versions to your .Net version and that ‘<em>Startup Command</em>’ is calling <em>dotnet </em>command for your executive dll (as in picture below).<br>You will need this so that you can check if your app is working when is deployed successfully.</li></ul><figure><img alt="Configuration tab in Azure App Service." src="https://cdn-images-1.medium.com/max/835/1*nStxToOffP3tL9P7as8fYg.png" /><figcaption>Configuration tab in Azure App Service.</figcaption></figure><ul><li>Create <em>GitLab repo</em>, install and configure ‘<a href="https://docs.gitlab.com/runner/"><em>GitLab runner</em></a><em>’</em> (<em>GitLab runner</em> is used for running CI/CD jobs in the pipeline. It can be installed locally on your machine or if you have GitLab hosted on some server, you will need to install and configure a runner there. Installing runner on Windows or Linux machine will matter for what we will use to deploy our Web API) and create one .yaml file.</li></ul><p>So let’s start with an actual example.</p><p>We have two options on how to deploy our app with GitLab CI/CD. As I’ve mentioned above, those two options depend on what machine the GitLab runner is installed and configured. If you use Windows machine, then GitLab runner is running your script in PowerShell and we need to use ‘<a href="https://docs.microsoft.com/en-us/powershell/azure/what-is-azure-powershell?view=azps-7.5.0"><em>Azure PowerShell</em></a>’ commands and if you are on Linux, then it uses Bash and we need to use ‘<a href="https://docs.microsoft.com/en-us/cli/azure/what-is-azure-cli"><em>Azure CLI</em></a>’.</p><p>In my case we were using a Windows machine, so I had to go with the PowerShell, but I will also cover the Linux version.</p><h3><strong>1. Azure PowerShell</strong></h3><ul><li>First, we need to be sure that ‘<em>Azure PowerShell</em>’ is installed on a machine where a runner is installed (local machine or server machine). You can find install instructions on this <a href="https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.2">link</a>.</li><li>Also, we will need ‘7Zip’ to be installed on the machine (will explain why later). You can download 7Zip from their <a href="https://www.7-zip.org/download.html">site</a>.</li></ul><p>Now you can check example code and below it you can find an explanation for each line.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/05bac79d632c6937ac4b6ac88180d0bd/href">https://medium.com/media/05bac79d632c6937ac4b6ac88180d0bd/href</a></iframe><ul><li><strong>(1)</strong> - The first line says that we are going to use .Net 6 SDK Image in our script. This means that we are free to use any ‘<em>dotnet</em>’ command from that SDK without the need to install it on our machine.</li><li><strong>(3–4)</strong> - Here we are setting ‘7z’ variable that is a full path to 7Zip exe file. Now is the part where I need to explain why we need 7Zip.<br>To deploy the app to Azure using Azure PowerShell or Azure CLI, we need to provide them with archived app files (from Microsoft docs: “<em>The content should be packaged in a ZIP file if using stacks such as .NET, Python, or Node, or a WAR or JAR file if using Java.</em>”). So we have to somehow compress our files and make Zip file. <br>Now this part again depends on what machine are you using for your app but on Azure. So if you are going to host your app on Windows machine in Azure you can use PowerShell command <a href="https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.archive/compress-archive?view=powershell-7.2"><em>Compress-Archive</em></a> to create your Zip file. But if you are hosting your app on the Linux machine (as it was in my case) you will have to use ‘<em>7Zip</em>’ for creating your Zip file. The reason you can’t use ‘<em>Compress-Archive</em>’ command in both cases is that this command uses ‘\’ when compressing files and when Azure tries to extract files on Linux machine you will get an error that it can’t resolve files (or something like that), and the reason is that Unix uses ‘/’ when compressing files so we have to go with alternative for compressing our files and that’s ‘<em>7Zip</em>’.</li></ul><p>Now we move to stages. First is build stage:</p><ul><li><strong>(10–16)</strong> - This is my configuration for my build stage but of course you can configure what best suits you. Just want to mention that <em>windows</em> in <em>tags </em>part, says which GitLab runner will run this job.</li><li><strong>(18–20) </strong>- This is a basic script for publishing .Net applications. We position to app root folder with PowerShell command <em>Set-Location</em> (<em>cd</em> also works) and then run <em>dotnet clean</em> and <em>dotnet publish</em>. My suggestion is to set a variable for ‘<em>&lt;PUBLISHED_FILES_PATH&gt;</em>’ so that you can reuse it in after-script.</li><li><strong>(22) </strong>- So after the script is successfully finished, then after-script is executed. And in this script, we are compressing our files and creating our Zip file. We are using PowerShell command <a href="https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.utility/invoke-expression?view=powershell-7.2"><em>Invoke-Expression</em></a> and 7z variable that we declared to execute 7Zip command for creating archive (or in case your app is hosted on a Windows machine, you can use <a href="https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.archive/compress-archive?view=powershell-7.2"><em>Compress-Archive</em></a> command). The order of arguments are (you can check more examples and arguments <a href="https://7ziphelp.com/7zip-command-line">here</a>): <br>- ‘a’ - means add or archive,<br>- ‘<em>&lt;ARCHIVE_LOCATION_PATH&gt;\&lt;YOUR_APP_NAME&gt;.zip</em>’ - we need to set where that Zip file will be saved and what will be its name (name could be whatever),<br>- ‘&lt;PUBLISHED_FILES_PATH&gt;\*’ - we need to set path to files we want to add to archive (* is a wildcard that says to take all folders and files in specified path),<br>- This is optional but in the end we can exclude some files from archive (e.g. pdb files).<br>For my example, I was using normal compression because our app is not that big, but you can specify also the best compression, but your build stage will take a bit more time depending on your app size.<br><strong><em>Notice</em></strong>: ‘7Zip’ can throw error while compressing your files, but your pipeline will still continue and be marked as successful. Be careful with this because we are using PowerShell <em>Invoke-Expression</em> command and it swallows any error thrown by the command executed inside of it (you will still see the error in the job report in GitLab). So if you see that your app is not working (or for e.g. new files are not deployed) first check if your files are being archived correctly (you can download artifacts from your build stage and check zip file if contains all your files).</li><li><strong>(25)</strong> - We just specify that our Zip file is Artifact for our build stage and it’s path. My suggestion is to use wildcards like in my case and not use full path to the Zip file, because with full path sometimes artifacts won’t be found (for some reason), but with wildcard it will search for that file recursively.</li></ul><p>Finally, we have deploy stage:</p><ul><li><strong>(28–36)</strong> - As for build stage, this is also my configuration for our deploy stage. Here I just want to mention that you will need to add dependency for build stage in <em>needs</em> array, so that when this job is started, we have Zip file downloaded from build stage so we have it for deploy.</li><li><strong>(39–41) </strong>- This is part for connecting to Azure. For connecting we are using <a href="https://docs.microsoft.com/en-us/powershell/module/az.accounts/connect-azaccount?view=azps-7.5.0"><em>Connect-AzAccount</em></a> command. There are a lot of different ways to connect to Azure (you can find examples in command docs), but in my case I was using a service principal account (Example 3 in their docs). The best practice is to store all your credentials as environment variables on your machine and then read them and use them for connecting to Azure. Here in my case I had to create an object called ‘<em>PSCredential</em>’ and to pass it with ‘<em>TenantId</em>’. And that’s it. We are now connected to our Azure project.</li><li><strong>(42)</strong> - So before you upload your files, you will need first to stop your app (if your app is already stopped, nothing will happen). To stop your app service, you will need to use <a href="https://docs.microsoft.com/en-us/powershell/module/az.websites/stop-azwebapp?view=azps-7.5.0"><em>Stop-AzWebApp</em></a> and just pass to it your ‘<em>ResourceGroupName</em>’ and ‘Name’ of your Azure app.</li><li><strong>(43)</strong> - So the main command for deploying/publishing your app is <a href="https://docs.microsoft.com/en-us/powershell/module/az.websites/publish-azwebapp?view=azps-7.5.0">Publish-AzWebApp</a>. To this command you need to provide your ‘<em>ResourceGroupName</em>’, ‘Name’ of your Azure app and, of course, your full path to your Zip file that contains your compressed app files. With a ‘needs’ keyword on line (29) we are sure that our Zip file will be ready for our deploy stage. On the end of the command, we also need to use ‘-Force’ that will force any confirmation that pops up (like overwriting files confirmation). Also, there are more parameters that can be used in this command, so go to their docs and check them.</li><li><strong>(44) </strong>- In the end, because we stopped our app we need of course to start it again. For this we are going to use, you won’t believe it, <a href="https://docs.microsoft.com/en-us/powershell/module/az.websites/start-azwebapp?view=azps-7.5.0"><em>Start-AzWebApp</em></a> and provide same parameters as for stop command, so your ‘<em>ResourceGroupName</em>’ and ‘Name’ of your Azure app.</li></ul><p>And that’s it! Now you can go to your Azure and check if your app is working. Remember that it can take about 3–5 minutes for your app to fully boot up and be ready for use.</p><h3>2. Azure CLI</h3><p>So now I’m going to show you how to deploy your app but with ‘<em>Azure CLI</em>’. Build stage is same so I’m going to show you only deploy stage.</p><ul><li>First, you need to be sure that ‘<em>Azure CLI</em>’ is installed on your machine. <a href="https://docs.microsoft.com/en-us/cli/azure/install-azure-cli-windows?tabs=azure-cli">Here</a> you can find the installer and instructions for it.</li></ul><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0ee217f6764ef18123ac368d48ec8828/href">https://medium.com/media/0ee217f6764ef18123ac368d48ec8828/href</a></iframe><ul><li><strong>(1–12) </strong>- It’s all the same configuration as one used in PowerShell example, so nothing new.</li><li><strong>(13) </strong>- Now, for connecting (login) to Azure, we are using Azure CLI command <a href="https://docs.microsoft.com/en-us/cli/azure/authenticate-azure-cli#sign-in-with-a-service-principal">az login</a>. In this simple example, we are using login using your azure username and password. So just pass your username and password for your Azure account and that’s it. In their docs for this command you can find other ways to login, but I think this is the simplest one.</li><li><strong>(14) </strong>- Using Azure CLI instead of three commands for stopping, deploying and starting our app again, we can use one command <a href="https://docs.microsoft.com/en-us/cli/azure/webapp?view=azure-cli-latest#az-webapp-deploy">az webapp deploy</a>. To this command you need to provide your ‘<em>ResourceGroup</em>’ name, ‘Name’ of your Azure app, ‘SrcPath’ to your zip file and ‘Type’ of file that you are uploading (in our case is zip but this type parameter is here because it is possible to upload also other files like war, jar, etc…). Also crucial parameter that you need to use is ‘<em>--restart</em>’, because this parameter is replacing stopping and starting commands (there are also commands <em>az webapp stop</em> and <em>az webapp start</em> for that if you maybe need them). Check also Microsoft docs for this command for more optional parameters.</li></ul><p>And that’s it! Now check in Azure if your app is up and running.</p><p>Finally, we came to the end!🥳<br>As you saw in this examples doing deploy of .Net 6 Web Api with Azure CLI is waaaay easier. Remember that what you’re going to use depend on which GitLab runner are you using. But whatever approach you use, I hope this story is going to help you. I really tried to explain everything as detailed as possible, and also I tried to leave links to all commands and links for all installs so that you can take a look a bit more if you want.<br>So, I really hope you found this post helpful, and that you liked it. And if that’s the case, I would appreciate if you could leave a clap and follow 😁</p><p>P.S. Guys, if you have found any mistakes or you have any suggestion or question, please don’t hesitate to comment I will appreciate it a lot! Also, I will try to respond to everyone as soon as possible. Cheers!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b1e28e6b13dc" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>