Web Deployment Automation - GitHub Actions, Azure Web Apps, and Appsettings

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ต.ค. 2024
  • The process of deploying a web application should be an automated one. Not only is this a best practice, it is also a fairly simple process. No longer does a CI/CD process need to be intensive and scary. The same is true for handing settings and secrets on the deployed site.
    In this video, we are going to build out a simple C# web application using Blazor. That is just so we have something to deploy. From there, we are going to add it to GitHub. After that, we are going to go to Azure to set up a free web application with automated deployments from GitHub using GitHub Actions. Finally, we will update the environment variables in Azure to override our settings in our Appsettings file. This process will allow us to automatically deploy new updates to our site automatically every time we push a commit to GitHub, and it will allow us to have secure settings in Azure that even our developers cannot access.
    Full Training Courses: IAmTimCorey.com

ความคิดเห็น • 44

  • @loadiam
    @loadiam 3 หลายเดือนก่อน +8

    Just opened TH-cam search for a video to double check the process for deploying to Azure using GitHub actions and this was on my start page. Perfect timing as always Tim.

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน +3

      Great! I am glad it was helpful.

  • @codeticket
    @codeticket 3 หลายเดือนก่อน +3

    I just woke up this morning smiling with this video.

  • @Britney.J
    @Britney.J 3 หลายเดือนก่อน +4

    Oh my gosh.... it's like you read my mind on what I wanted to learn next!

  • @no-bc4kc
    @no-bc4kc 3 หลายเดือนก่อน +1

    Really love the video. Just on a side note, I was having tons of issues with deployment. Turns out the generated YAML file from Azure was using all the latest [use:actions] i.e @v4. Took me a while to research and then noticed your generated YAML file was using various versions of [use:actions]. Only then after 10 failed deployments did I manage to actually get it deployed successfully. Hopefully this can help anyone else running into deployment issues.

    • @IAmTimCorey
      @IAmTimCorey  2 หลายเดือนก่อน +1

      Thanks for sharing!

  • @faisalalhoqani6151
    @faisalalhoqani6151 หลายเดือนก่อน

    Great demonstration dear Tim thank you and keep it up dear.

    • @IAmTimCorey
      @IAmTimCorey  หลายเดือนก่อน

      You are very welcome.

  • @Tom-ry3fl
    @Tom-ry3fl หลายเดือนก่อน

    Hi Tim, huge fan firstly, keep up the great work. Do you cover off issues in Blazor regarding the constant loss of connection to the server?

    • @IAmTimCorey
      @IAmTimCorey  หลายเดือนก่อน

      I don't have a specific video on it, although that's less of a problem since Blazor Web Apps came out. They don't need to keep a constant connection open (if you are using Auto), which makes things a LOT better.

  • @chidieberelevi3344
    @chidieberelevi3344 3 หลายเดือนก่อน +1

    Thank you Tim. Really insightful

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน +2

      You are welcome.

  • @torrvic1156
    @torrvic1156 2 หลายเดือนก่อน

    Awesome tutorial! Thanks a lot Tim!
    Really liked this little technique with parentheses which allows to put some complicated C# code with angle brackets inside of html stuff in Blazor and also this video allowed me to finally understand in general what is CI/CD process and how impressive Azure is (never used it though because it is not available around my parts).

    • @IAmTimCorey
      @IAmTimCorey  2 หลายเดือนก่อน +1

      I am glad it was helpful.

  • @antoniusivan8767
    @antoniusivan8767 3 หลายเดือนก่อน

    The dotnet eshop demo is so great tim. Just 8 month I learn, full stack blazor, YARP, Serverside e-commerce rendering, GRPC, Minimal API, Simple Postgre, CMS, FluentUI+Tailwind, Bootstrap 5, Blazor Hybrid, Dapper DataAccess, Azure Container Apps, Redis. Not yet the Rabbit MQ. XD. Wish you open part time job to help you from Indonesia. XD

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน

      Sorry, I don't have any part-time positions available at this time.

  • @patrickizekor6463
    @patrickizekor6463 3 หลายเดือนก่อน +1

    Thanks for the video Mr Corey. Just wondering where the CI(automated building and testing of code) takes place.

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน +1

      Technically, we are doing both at once with our GitHub Action. We are doing the build and then immediately deploying it. If you had unit tests, you would include those in the build process.

  • @pavankumard5276
    @pavankumard5276 3 หลายเดือนก่อน +1

    Really good video thanks for this. I think you could have explained the Yaml file a bit and showed the difference in the CI part and CD part

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน

      Thanks for the suggestion.

  • @noahyannis2465
    @noahyannis2465 2 หลายเดือนก่อน

    You're a legend Tim :)

    • @IAmTimCorey
      @IAmTimCorey  2 หลายเดือนก่อน

      Thank you!

  • @toyokenstudio
    @toyokenstudio 3 หลายเดือนก่อน

    Great! Thanks for this tutorial! Very useful. 😊

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน

      You are welcome.

  • @kylekeenan3485
    @kylekeenan3485 3 หลายเดือนก่อน

    Thanks for this, I have been doing(forced) into Azure Integration services recently, using Logic apps and functions with liquid transforms and service bus and was wondering how the website side of Azure worked. This helped me get a good starting point.

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน

      I am glad it was helpful.

  • @ruwantharatnayake5004
    @ruwantharatnayake5004 3 หลายเดือนก่อน +1

    Hi @IAmTimCorey, Can you do a video or video series on Azure application insights, how we can use logs to investigate issues etc.

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน +1

      Thanks for the suggestion. Please add it to the list on the suggestion site so others can vote on it as well: suggestions.iamtimcorey.com/

  • @AtikBayraktar
    @AtikBayraktar 3 หลายเดือนก่อน

    and just yesterday in a job interview, I said I need real-world experience for CI/CD.. :)

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน +2

      Now you have an example to get you started.

  • @mahmoudzareefWork
    @mahmoudzareefWork 2 หลายเดือนก่อน

    Thanks a lot, is there's a way for commit for every code save?

    • @IAmTimCorey
      @IAmTimCorey  2 หลายเดือนก่อน +1

      Not automatically. Besides, a commit should be a specific change, not just a save history.

    • @MahmoudZareef
      @MahmoudZareef หลายเดือนก่อน

      @@IAmTimCorey OK, thanks for the info and effort you put into this... BTW, your videos are my goto in c#, keep pushing.

  • @vuhoang5903
    @vuhoang5903 3 หลายเดือนก่อน

    What if I want to deploy only a project in my solution? For example, there is a web API project and a blazor project and I want to deploy them on 2 separate web apps? The git repository still contains both projects.

    • @misterjib
      @misterjib 3 หลายเดือนก่อน

      in azure pipeline build the solution. in the release you can specify what projects to deploy from the content of the build zip

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน +2

      The YAML script specifies which project gets deployed. You can change this and have two scripts (one per project) or you can modify the script to have two deployments (one per project).

  • @taufikherjanto
    @taufikherjanto 3 หลายเดือนก่อน +2

    HOw to deploy to non azure host/server?

    • @IAmTimCorey
      @IAmTimCorey  3 หลายเดือนก่อน +4

      That depends on the system you are deploying to (there are multiple different ways to do deployments). I have it on my list to potentially show at least one way, though.