<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: KM Cloud Tech</title>
    <description>The latest articles on DEV Community by KM Cloud Tech (@kmcloudtech).</description>
    <link>https://dev.to/kmcloudtech</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F850199%2Ff5d0eda5-3acc-4e66-8810-37b7743f8b0b.jpg</url>
      <title>DEV Community: KM Cloud Tech</title>
      <link>https://dev.to/kmcloudtech</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/kmcloudtech"/>
    <language>en</language>
    <item>
      <title>Azure Weather Web App AZ-204 Project 1</title>
      <dc:creator>KM Cloud Tech</dc:creator>
      <pubDate>Tue, 29 Aug 2023 18:04:00 +0000</pubDate>
      <link>https://dev.to/kmcloudtech/azure-weather-web-app-az-204-project-1-57fh</link>
      <guid>https://dev.to/kmcloudtech/azure-weather-web-app-az-204-project-1-57fh</guid>
      <description>&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;In today's digital age, cloud services are the backbone of many applications. Azure, Microsoft's cloud platform, offers a plethora of services to get applications up and running in no time. In this post, I’ll share my journey in creating a weather application using Azure's array of services.&lt;/p&gt;

&lt;p&gt;The Github repository for this project is &lt;a href="https://github.com/Kenseventy/weatherapp"&gt;Github&lt;/a&gt;&lt;br&gt;
The actual web app page is &lt;a href="http://weather.kmcloud.tech"&gt;http://weather.kmcloud.tech&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This is the first part of four related to MadeByGPS’s AZ-204 related projects found in this &lt;a href="https://www.youtube.com/watch?v=Ny5SZcV7mbE"&gt;video&lt;/a&gt;.&lt;br&gt;
I’ll be making some small adjustments along the way but I want to present what I’ve learned related to the following items:&lt;/p&gt;

&lt;p&gt;Azure App Service Web App &lt;br&gt;
Azure Container Registry&lt;br&gt;
Azure Container Instance&lt;br&gt;
Azure Container Apps &lt;br&gt;
Azure Functions&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Create an Azure App Service Web App&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Azure App Service is like a toolbox from Microsoft that makes it easy to put web apps on the internet without worrying about all the technical stuff in the background. At the start of this project, I used this toolbox to set up the web app. I like to think of this as setting up my own little space on the internet where the weather app can live and be visited by people.&lt;/p&gt;

&lt;p&gt;Creating and setting up a Flask application with Python would be straightforward and with some configuration of the Azure App Service, I would be able to get this application up and accessible to the internet.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Developing the basic Weather Application&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Before I started using Azure's many tools, I first needed the heart of the project: a simple web application that could talk to weather APIs. I used Python and Flask to create a simple web page with a text field that accepts input, along with a route that would search when the button is pressed. Functionality was needed when the button was pressed, the site would call a weather API and be able to display the relevant information. &lt;/p&gt;

&lt;p&gt;The weather API I picked was the OpenWeatherMap API for this. It's straightforward and accessible, making it easy for us to get basic weather details. This choice was important because it meant the main app would work well, even as I added more features with Azure.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;def get_weather_data(city_name):
    if not city_name:
        return None

    # OpenWeather API details
    API_URL = "http://api.openweathermap.org/data/2.5/weather"
    API_KEY = os.environ.get("WEATHER_API_KEY")

    # Full URL Adding units=metric to get temperature in Celsius.
    full_url = f"{API_URL}?q={city_name}&amp;amp;appid={API_KEY}&amp;amp;units=metric"

    try:
        response = requests.get(full_url)
        data = response.json()

        # Check for valid response from OpenWeather API
        if data.get("cod") != 200:
            return None

        # Process and return the data
        return {
            "city": data["name"],
            "temperature": data["main"]["temp"],
            "description": data["weather"][0]["description"]
        }

    except Exception as e:
        # Handle any exception that arises when making the API call
        print(e)
        return None

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Containerization&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;To ensure the web application was isolated and portable, I containerized it. Using Docker, I  was able to package the application with all its dependencies, ensuring that it could run consistently across different environments. &lt;/p&gt;

&lt;p&gt;This step is vital, especially when working with cloud platforms like Azure, because it eliminates the "it works on my machine" problem. By containerizing the application, I made it easier to manage, deploy, and scale. After containerizing the app, I pushed the Docker image to Azure Container Registry, ensuring a secure and private storage for the container image(s). &lt;/p&gt;

&lt;p&gt;This approach streamlined the deployment process, particularly when I decided to test the application using Azure Container Instance and, later on, deploy it to Azure Container Apps. This ensured that the application, from development to deployment, was efficient, consistent, and cloud-ready.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;FROM python:3.8-slim

WORKDIR /app

COPY requirements.txt .
RUN pip install -r requirements.txt

COPY . .

CMD ["flask", "run", "--host=0.0.0.0", "--port=80"]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Azure Container Registry&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;As mentioned in the last section, the ACR was where I would store the Docker Image. The registry streamlines the process of storing and managing those images, ensuring that they're kept in a secure environment. The added benefit of ACR is its seamless integration with other Azure services. &lt;/p&gt;

&lt;p&gt;With the image in the set-up Azure Container Registry I was able to test the application using Azure Container Instance first for testing before deploying it to Azure Container Apps. Not only did it make deployments and testing quicker, but it also ensured that I had a centralized and consistent version of the app ready for deployment when needed.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Azure Container Instance&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;After containerizing the web application and storing it in Azure Container Registry (ACR), it was essential to test it before a full-scale deployment. For this, I used Azure Container Instance (ACI). Unlike traditional container orchestrators which might require complex setup and configuration, ACI presents a simpler approach. It's designed to run containers without the complexity of managing underlying infrastructure or orchestrating multiple container instances. &lt;/p&gt;

&lt;p&gt;This made ACI an excellent choice for my use case; it allowed me to quickly spin up the container and see the application in action in a real-world Azure environment. By testing with ACI, I ensured that the application was ready for the challenges of a live environment, along with ensuring its stability and performance. This step was critical as it provided insights and highlighted any potential issues, ensuring a smoother transition when I decided to deploy the app on Azure Container Apps.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Azure Function&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Delving deeper into Azure's capabilities, I decided to give the application an expanded feature by using an Azure Function. This serverless solution allowed us to build an alerting mechanism that triggered whenever specific weather conditions were met, Specifically the web page would show if the temperature was under 20° celsius triggering a ‘Sweater Alert’. &lt;/p&gt;

&lt;p&gt;The beauty of Azure Functions lies in its event-driven nature, making the application not just informative based on the search but also proactive in providing insight into weather conditions and proactively alerting..&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Integration of the Azure Function&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Using Flask, I was able to enhance the basic web application to introduce the dynamic ‘Sweater Alert’ mechanism. With just a few tweaks in Flask routes and templates, I seamlessly integrated the alert into the web page.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Azure Container Apps&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;To get the Container Apps up and running, I started by leveraging the Azure CLI. After logging into Azure using az login, I navigated to the specifics of the project with az containerapp create. Following the initial setup, I pointed the application to the image in Azure Container Registry using the --image parameter. &lt;/p&gt;

&lt;p&gt;Compared to Container Instances, Container Apps have more granular control with the use of environments. For example you can adjust Network settings or have applications share a log analytics workspace in the same environment. Having the environment setup was a necessity for having the Container App set up and running.  &lt;/p&gt;

&lt;p&gt;From there I was provided a URL that was where the Container App was up and running but I wanted to include the site into my ‘kmcloud.tech’ ecosystem. From the Azure portal, I created a ‘custom domain’ entry and validated the DNS with my DNS provider.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Push to GitHub&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;To implement version control and make the CI/CD processes make more sense I put the codebase up to Github. This also opens up opportunities for collaboration with other developers and engineers to look at my code, potentially give advice or even contribute to this project.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
Git add .
Git commit -m “First commit”
Git push 

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;CI/CD Implementation&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;To streamline the deployment process, I implemented CI/CD pipelines, automating the process from the codebase to the live application. Using GitHub Actions, I developed a two-pronged approach to address both Docker and Azure Functions.&lt;/p&gt;

&lt;p&gt;Before this could be completed with best practices, I needed to create a service principal account that would interact with the Azure services. This would allow a programmatic way to use services in the Subscription without providing user/admin credentials.&lt;/p&gt;

&lt;p&gt;The Docker process .yml file was structured to build a Docker image from the included Dockerfile in the repo.. This .yml file facilitates the setting up the environment and installs dependencies. It then pushes the fresh container image to Azure Container Registry. To facilitate this, I stored credentials (including the service principal) as secrets within the GitHub repository. This ensures security while allowing GitHub Actions to authenticate with Azure services programmatically.&lt;/p&gt;

&lt;p&gt;For the Azure Function, I developed a separate .yml pipeline. This .yml file starts with setting up the environment then using the stored secrets (along with the service principal) in the GitHub repository, the Github Actions logs into Azure, allowing the pipeline to deploy the Azure Function programmatically. Finally, the GitHub action cleans up by logging out of Azure.&lt;/p&gt;

&lt;p&gt;By integrating these CI/CD pipelines, reinforced with the stored secrets, I’m able to optimize the deployment workflow. This ensured that the Web App, Container Image and Azure Function stayed synchronized with the latest changes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Documentation&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Last but not least, I wrote out this blog post to document what I had done to get everything up and running. This should make it easier for others to replicate this process, understand design choices, and contribute to the project.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Spinning up this project and associated Azure resources was a fantastic learning experience. I was able to learn a ton about Azure Containers including the Registry, Instances and Apps along with a deeper knowledge of Azure Functions. I was also able to learn more about the az cli tool where I could deploy services with a single command instead of clicking around in the Azure portal.&lt;/p&gt;

&lt;p&gt;In the near future, I will be returning to this project and implementing IaC with Terraform to allow even more granular control of cloud resources. One other thing I could implement is the CI/CD splitting of the Test and Prod environments. I know there's a way to differentiate when a test image is uploaded and when a prod image is uploaded but that would take some research.&lt;/p&gt;

&lt;p&gt;I hoped you learned something through my journey, This was a lot of trial and error before getting everything up and running properly. Using the skills and resources from this project I will be moving onto "Azure Document Vault with Expiry &amp;amp; CDN Integration (Develop for Azure storage)"&lt;/p&gt;

&lt;p&gt;Stay tuned for that blog post.&lt;br&gt;
Thanks for reading,&lt;br&gt;
-Kenton&lt;/p&gt;

</description>
      <category>azure</category>
      <category>python</category>
      <category>docker</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Kenton's API v1</title>
      <dc:creator>KM Cloud Tech</dc:creator>
      <pubDate>Fri, 27 May 2022 15:48:04 +0000</pubDate>
      <link>https://dev.to/kmcloudtech/kentons-api-v1-4fa0</link>
      <guid>https://dev.to/kmcloudtech/kentons-api-v1-4fa0</guid>
      <description>&lt;p&gt;Hello, In this blog post I will be talking about how I set up my Cloud Resume Challenge website to include REST API functionality.&lt;/p&gt;

&lt;p&gt;As a bit of preface, I always viewed REST APIs as a gateway for my Powershell skills to be able to reach out and interact with the internet. When Powershell was first presented to me, it was described as a tool to make Windows administration tasks quicker and more efficient. It's very useful for Windows server and specifically Server Core but what good is a modern computer if it can't connect to the internet? &lt;/p&gt;

&lt;p&gt;First it was web scraping with Invoke-Webrequest but this didn't give the exact information that I wanted. There was too much HTML included after drilling down past the status codes and raw content.  In came Invoke-Restmethod. What a game changer, I could interact with HTTP endpoints in a familiar way and chain other commands based on information from those endpoints.&lt;/p&gt;

&lt;p&gt;I drummed up some ideas about what information would be relevant to provide by JSON. To me, my resume made the most sense.&lt;/p&gt;

&lt;p&gt;What are the steps that I need for this?&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Node js and Express js to host the REST API&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Endpoints&lt;/li&gt;
&lt;li&gt;JSON file for Resume&lt;/li&gt;
&lt;li&gt;Basic Authentication&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Host on Github for CI/CD&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Host on Azure to have a public endpoint&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h1&gt;
  
  
  Node js and Express js to host the REST API
&lt;/h1&gt;

&lt;p&gt;What did I need to do to set this up?&lt;br&gt;
I used Javascript in the main Cloud Resume Challenge so I started there, maybe there was a framework that had REST API functionality that would be built in?&lt;/p&gt;

&lt;p&gt;I found it, Express js on top of Node js.&lt;/p&gt;
&lt;h2&gt;
  
  
  Endpoints
&lt;/h2&gt;

&lt;p&gt;After following a couple guides I was able to spin up a local instance of Node js that I could make an invoke-Restmethod call to and get the information that I set up to serve.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app.get('/api', (req, res) =&amp;gt; {

res.send('🔥🔥🔥');

})

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  JSON file for Resume
&lt;/h2&gt;

&lt;p&gt;What's next? Well, Let's find a template for my resume in JSON.&lt;/p&gt;

&lt;p&gt;I copied from the &lt;a href="https://jsonresume.org/schema/"&gt;jsonresume.org&lt;/a&gt; schema and made some tweaks to get them more inline with my skills.&lt;/p&gt;

&lt;p&gt;I needed to add that JSON as an endpoint. Instead of putting the whole JSON in the response, everywhere I looked said to have a separate file and have the main file reference the JSON file.&lt;/p&gt;

&lt;p&gt;Two things needed to be added for that, fs and the path as a const.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const fs = require("fs")

const resume = require("./resume.json")

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app.get('/resume', (req, res) =&amp;gt; {
    res.header("Content-Type",'application/json');
    res.sendFile('resume.json' , {root :__dirname});   
}); 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The JSON template included a place to put a picture. I knew that pictures can't exactly be served by JSON but I figured that I could have an endpoint that shows a picture if you go to it in a browser.&lt;/p&gt;

&lt;p&gt;I first thought about adding the image to the Github repo but then I realized that the image is already in Azure Blob storage. What if I just have a separate page that linked back to that image.&lt;/p&gt;

&lt;p&gt;With some research I determined that an endpoint can just be linked to a different HTML page. From that HTML page we can display the linked picture.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app.get('/resume/image', (req, res) =&amp;gt; {
    res.sendFile(__dirname + '/image.html');
});
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;img src="https://azureresumekm.blob.core.windows.net/$web/images/km.jfif" alt="My_Picture"&amp;gt;&amp;lt;/img&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There I am and accessible at the /resume/image endpoint.&lt;/p&gt;

&lt;h2&gt;
  
  
  Basic Authentication
&lt;/h2&gt;

&lt;p&gt;One last piece of the puzzle to make this unique, Authentication.&lt;br&gt;
Previously, I was able to host a REST API but I didn't like that you could just go to the website and see the information. I wanted there to be &lt;em&gt;a&lt;/em&gt; hoop to jump through to access the information. I understand that Basic authentication isn't used that much and putting it right in the code that is going on Github is insecure but this is only to demonstrate.&lt;/p&gt;

&lt;p&gt;That said, I set up a couple Basic authentication accounts in the index file that will kick back a 401 if the credentials are not inputted correctly. I have also added a challenge so that if the website is visited by a browser and doesn't include credentials it will ask for them.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app.use(basicAuth({
    users: {'user': "resume" },
    challenge: true
}))
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So I have all my files ready, I run &lt;code&gt;node .&lt;/code&gt; on my VSCode instance and try the endpoints. Success, At least on localhost. I also try accessing through Powershell but I hit a bump. Invoke-restmethod wouldn't work with basic authentication. I do some research and find the official documentation for the command and it has the -authentication parameter. I didn't see that available in my version of Powershell so I decided to give the shell an update.&lt;br&gt;
Right after the update we were able to use the -cred, -authentication and the -allowunencryptedauthentication parameters to initiate a call.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Invoke-RestMethod http://localhost:8080/resume -cred resume 
-authentication Basic -AllowUnencryptedAuthentication
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Host on Github for CI/CD
&lt;/h1&gt;

&lt;p&gt;From what I could recall from the original CRC and website, getting the Github repo set up for this shouldn't have been an issue. &lt;br&gt;
&lt;code&gt;git init&lt;/code&gt;&lt;br&gt;
&lt;code&gt;git add -A&lt;/code&gt;&lt;br&gt;
&lt;code&gt;git commit -m "first commit"&lt;/code&gt;&lt;br&gt;
&lt;code&gt;git push&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Looking back, I'm not sure that anything past the init was necessary but I was lost in VSCode and doing all the commands didn't hurt.&lt;/p&gt;

&lt;p&gt;Next, I used a Github tutorial that had the proper az cli commands to get started and had the correct YAML file to make the connection.&lt;/p&gt;

&lt;p&gt;I had a bit of trouble with the first run of Github actions, The npm test was failing and I wasn't sure why. I looked into it and my package.json file literally had an error code built in.&lt;br&gt;
"test": "echo \"Error: no test specified\" &amp;amp;&amp;amp; exit 1"&lt;br&gt;
I'm not sure the purpose of it but the complete removal of the test attribute seemed to work.&lt;/p&gt;

&lt;p&gt;I ran into another issue, I copied over the secret key like the guide suggested but I noticed that I copied in the name that didn't match the YAML file. I corrected that and I was able to make a connection with Github Actions.&lt;/p&gt;

&lt;h1&gt;
  
  
  Hosting on Azure
&lt;/h1&gt;

&lt;p&gt;Through the Github tutorial I used the az cli to create a new app service plan and web app to host the node app. From there I wanted to add a custom domain. In the past when I tried hosting an endpoint on my website I had trouble with the static web app. The specific limitation I ran into was that only the 'index' page was accessible, I couldn't find a way to have a /resume added onto this web app. Instead of migrating away from the static web app, I decided to implement a sub domain.&lt;/p&gt;

&lt;p&gt;rest.kmcloud.tech&lt;/p&gt;

&lt;p&gt;This is something I will probably change in the future, When I look up best practices for REST APIs I see that it makes more sense to have endpoints be on the root of the webpage.&lt;/p&gt;

&lt;h1&gt;
  
  
  Conclusion
&lt;/h1&gt;

&lt;p&gt;Finally, All the pieces are working together to serve my resume in JSON to anyone on the internet.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;curl rest.kmcloud.tech/resume -u user:resume&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;Invoke-RestMethod http://rest.kmcloud.tech/resume -cred user &lt;br&gt;
-authentication Basic -AllowUnencryptedAuthentication&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Through Github actions I can also make changes locally, quickly test them and push them all the way to Azure. There’s no tinkering with files or settings, it just works.&lt;/p&gt;

&lt;p&gt;The Github repo for this project is here.&lt;br&gt;
&lt;a href="https://github.com/Kenseventy/Resume-API"&gt;https://github.com/Kenseventy/Resume-API&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In the future I hope implement a ‘counter’ just like the website and also a ‘guestbook’ of some sort that stores actual responses in a database.&lt;/p&gt;

&lt;p&gt;Thanks for checking out this blog post, I know it’s long and maybe has some incorrect information but I see this blog as a place to write down my thoughts and record some of my work. &lt;/p&gt;

&lt;p&gt;If this helps even one person that would be great.&lt;/p&gt;

&lt;p&gt;Thanks,&lt;br&gt;
-Kenton&lt;/p&gt;

</description>
      <category>azure</category>
      <category>cloudresumechallenge</category>
      <category>node</category>
    </item>
    <item>
      <title>Kenton's Cloud Resume Challenge</title>
      <dc:creator>KM Cloud Tech</dc:creator>
      <pubDate>Tue, 19 Apr 2022 20:53:51 +0000</pubDate>
      <link>https://dev.to/kmcloudtech/kentons-cloud-resume-challenge-3iak</link>
      <guid>https://dev.to/kmcloudtech/kentons-cloud-resume-challenge-3iak</guid>
      <description>&lt;p&gt;This is my blog post about the completed Cloud Resume Challenge.&lt;/p&gt;

&lt;p&gt;My completed site is &lt;a href="http://kmcloud.tech"&gt;http://kmcloud.tech&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I decided to take the Azure flavour of this challenge as I had the Azure Administrator certification.&lt;/p&gt;

&lt;p&gt;There were a lot of technologies that I was able to work with that sharpened my Azure skills.&lt;/p&gt;

&lt;h2&gt;
  
  
  Frontend
&lt;/h2&gt;

&lt;p&gt;For the frontend I was able to implement Azure Storage and Static Web Apps, Azure CDN and Git.&lt;/p&gt;

&lt;p&gt;I made some modifications to an existing HTML site along with the accompanying CSS files, I may try to make more adjustments in the future.&lt;/p&gt;

&lt;p&gt;One big thing I needed to figure out was how to initiate steps on the web page being loaded.&lt;br&gt;
Javascript was the best option because of the eventlisteners it had and how it could see the ContentLoaded event of the webpage.&lt;br&gt;
From there we could call an app that would host a counter.&lt;/p&gt;

&lt;h2&gt;
  
  
  Backend
&lt;/h2&gt;

&lt;p&gt;For the backend I was able to implement CosmosDB, Azure Functions, Azure Storage and Github Actions.&lt;/p&gt;

&lt;p&gt;For the backend I created a C# function that connected into CosmosDB and got the current number for visitors and updated it into the same database.&lt;/p&gt;

&lt;p&gt;From VSCode I was able to deploy the function to Azure and host it there.&lt;br&gt;
I did all the coding and designing in VS Code which was new for me. I had some trouble getting the function deployed to Azure for a while because the folder I had open in VS Code wasn't the root where the function was. I eventually opened the backend folder and things started to flow. &lt;/p&gt;

&lt;h2&gt;
  
  
  CI/CD and Git
&lt;/h2&gt;

&lt;p&gt;This was probably the part that got me the most excited. I could host something locally and push it to the internet and the repo would make the changes automatically. I used GitHub Actions for this and with a small number of tweaks to Microsoft's template files, things were running moving smoothly.&lt;/p&gt;

&lt;p&gt;Being able to make a small change and not have to worry about moving files around or making sure you have the right file in the right place was exciting for me.&lt;/p&gt;

&lt;h2&gt;
  
  
  Next Steps
&lt;/h2&gt;

&lt;p&gt;I think the next thing I wanted to implement was a REST api interface, specifically where I can invoke-restmethod in Powershell and get a response.&lt;/p&gt;

&lt;p&gt;This isn't a 'next step' at this point but when I started the challenge I also wanted to get the Azure Solutions Architect Expert certification and I completed that on April 5th.&lt;/p&gt;

&lt;h2&gt;
  
  
  Thanks
&lt;/h2&gt;

&lt;p&gt;I wanted to give a quick shout out to Forrest Brazeal for writing the Cloud Resume Challenge book. I also wanted to thank &lt;a href="https://www.youtube.com/madebygps"&gt;Gwyn Peña-Siguenza&lt;/a&gt; for the guide video related to Azure and the rest of her Cloud/Azure content. &lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
