In February Come Cloud With Us is hosting a Kubernetes panel with some of the industry’s BEST Kubernetes experts. I am honored and humbled to be one of the panelists. This panel consists of K8s experts from Dell, Google, Microsoft, Intercept, United Wholesale Mortgage, and Admincontrol. This is a global panel with panelists and hosts from the United States, Norway, United Kingdom, and Canada. Several of the panelists are also authors, Microsoft MVP’s and CNCF Ambassadors.
Here is a breakdown of the hosts and the panelists:
The panel will discuss Kubernetes and answer attendee questions. This will be a virtual event. This will be an event that you DON’T want to miss! Mark your calendars for the event on Thursday, February 16, 2023 4:00PM-5:30PM CST!
I am excited to announce that I published a Python course on Pluralsight! This course is titled “Python for Linux System Administration“. This is my 17th course with Pluralsight overall and 6th for 2022. It will teach you how to utilize Python to administer Linux servers. This course is suitable for system administrators, DevOps engineers, and anyone working with servers running on cloud.
In this course, Python for Linux System Administration, you’ll learn the core of the Python language, various Python admin modules, & how to combine python scripts with other Linux tools for administration.
Here are some of the major topics that are covered in this course:
Gaining an understanding of the many benefits of using Python for systems administration.
What goes into setting up a Python environment and what IDE’s are the best options to assist you with your Python scripting.
How to install and use Python to Interact with the Linux System.
How to utilize Python modules such as the OS module & psutil to perform various administrative functions.
When you’re finished with this course, you’ll have the skills and knowledge about the core of Python, how it can be used for administration, why you would use it for administration, how to get setup for Python scripting, insight into Python administrative modules & scripts, as well as some real-world examples of administering Linux servers with Python.
I am excited to kick off the new year announcing that my 8th book has been published! This book is “Azure Arc-Enabled Kubernetes and Servers“.
I had the honor to co-author this book with a long-time friend and fellow Microsoft MVP John Joyner. This is John’s latest book since his last 8 years ago!
The forward was written by Thomas Maurer a former MVP and now Microsoft Azure Evangelist. This book was reviewed by fellow Microsoft MVP Adnan Hendricks and a chapter contributed by a buddy of mine Fred Limmer.
This book covers an exciting technology from Microsoft exploring Azure Arc-Enabled Kubernetes and Servers. This book is for DevOps professionals, system administrators, security professionals, cloud admins, and IT professionals that are responsible for servers or Kubernetes clusters both on-premises and in the cloud.
This book covers:
Introduces the basics of hybrid, multi-cloud, and edge computing and how Azure Arc fits into that IT strategy
Teaches the fundamentals of Azure Resource Manager, setting the reader up with the knowledge needed on the technology that underpins Azure Arc
Offers insights into Azure native management tooling for managing on-premises servers and extending to other clouds
Details an end-to-end hybrid server monitoring scenario leveraging Azure Monitor and/or Azure Sentinel that is seamlessly delivered by Azure Arc
Defines a blueprint to achieve regulatory compliance with industry standards using Azure Arc, delivering Azure Policy from Azure Defender for Servers
Explores how Git and GitHub integrate with Azure Arc; delves into how GitOps is used with Azure Arc
Empowers your DevOps teams to perform tasks that typically fall under IT operations
Dives into how to best use Azure CLI with Azure Arc
You can order the book and watch for its official release here:
Recently I was a guest on The Women in Linux Youtube channel. It was great to reconnect with Tameika Reed, Dionne Parler, and their team! Here is their website: www.womeninlinux.org. It has been many years since I was on their podcast. They have a weekly show named “How we Linux”. I highly recommend you check it out. I was on episode #14. We talked about many things from authoring tech books, the job market in tech, being a Microsoft MVP, the future of tech and even stocks! Check it out here:
The event is July 20th-21st. It will be a hybrid event (in-person & virtual). I will be speaking in person on the 20th.
Here is my session info:
GitOps and Kubernetes: a Winning Combo
GitOps is an emerging pattern for cloud-native applications. This operating model simplifies Kubernetes ops while simultaneously improving the developer experience. GitOps enables continuous delivery of configuration updates and application deployments to Kubernetes.
Through the lens of GitHub, Argo CD, and Azure Kubernetes Service, we’ll explore use cases and benefits, principles and practices, architecture and tooling, and what GitOps changes in our day-to-day.
Today I delivered my session on GitOps and Kubernetes: a Winning Combo. This was my first in-person event since the pandemic in the US started. I went on stage right after Ian Coldwater gave the keynote. Ian had an amazing keynote talking about community, how the pandemic and the murder of George Floyd impacted Minneapolis last year along with how the community came together. I presented to a crowd of a few hundred as well as another couple hundred online.
The online reach of this event was amazing. I even received a message that my session was watched by some folks in Japan!
In my session, we went on a journey through how companies should focus on being software businesses moving to digital, how the pandemic accelerated companies and consumers going digital as well as companies using Kubernetes and GitOps as a way to help power digital transformation.
The conference organizers did a great job pulling off another excellent event while ensuring everyone followed safety guidelines.
I was recently a guest on New Relic‘s Developer Relations team podcast “Observy McObservface” with Jonan Scheffler.
Jonan Scheffler and I talk about Microsoft’s Azure Kubernetes Service (AKS), Linux on Azure, how Microsoft’s been successful at working in enterprise and open source, where I believe GitOps & Kubernetes is eventually going to go, and my excitement in regards to AI and blockchain as well as how they’re going to impact the world. You can listen to the podcast and read the article links below.
Here is the link to the Ignite home page myignite.microsoft.com. I hope to see you on the digital Ignite event and in one of the Ask the Expert Sessions!
Being a part of several Ask the Expert sessions was really fun! My most memorable session was the Ask the Expert: Linux and PowerShell on Azure session.
This session was packed full of superstars from Microsoft product groups and fellow MVPs including; Jeffery Snover, Jason Helmick, Janaka Rangama, and Alexander Nikolić. Here is a screenshot from the session:
After the session, I tweeted about the session and shared some wisdom about PowerShell, and both Jeffery Snover and Jason Helmick retweet my tweet!
2020 is not all bad. It’s pretty cool when the inventor of PowerShell and the PowerShell Program Manager retweet you!
This is a great service if you just need to run a single container or even a couple of containers that you have in Docker Compose. This service is PaaS and abstracts away an orchestration system like Kubernetes. If you need insight into the Azure App Service Web App for Containers service check out the blog post on 4sysops.
In this long blog post I am going to take things a step further and walk-through the build & release of a Container from Azure DevOps to Azure Web App for Containers. The overall goal of this post is to help someone else out if they want to setup a build and release pipeline for building and deploying a container to Azure App Service. We will use a very simple PHP web app I built that will run in the container.
Here are the components that are involved in this scenario:
Azure Container Registry (ACR): We will use this to store our container image. We will be pushing up the container image and pull it back down from the registry as a part of the build and release process.
Azure DevOps (ADO): This is the DevOps tooling we will use to build our container, push it up to ACR, pull it down into our release pipeline and then deploy to our Azure App Service.
App Service Web App for Containers: This is the web server service on Azure that will be used to host our container. Under the hood this will be a container that is running Linux and Apache to host the PHP web app.
Here is the data Flow for our containerized web app:
Deploy the Azure App Service Web App for Containers instance
Deploy the Azure Container Registry
Deploy the Azure DevOps organization and project, create repository to host the code, clone repository in VS Code (Not shown in this blog post. Assume you know how to this up.)
Update the application code (PHP code and Docker image) in Visual Studio code
Commit application code from Visual Studio code to the Azure DevOps repo (Not shown in this blog post. Assume you know how to this up.)
Setup build and then run container build and push the container image to ACR
Setup release pipeline and then kick off the release pipeline pulling down the container image from ACR and deploys the container to the App Service Web App for Containers instance.
Here is a diagram detailing out the build and release process we will be using:
Ok. Let’s get into the setup of core components of the solution and the various parts of the build and release pipeline.
For starters this solution will need a project in Azure DevOps with a repo. Create a project in Azure DevOps and a repo based on Git. Name the repo exerciseoftheday. Next up let’s create the core framework we need in Azure.
Deploy Azure App Service Web App for Containers
Let’s create the Azure App Service Web App for Containers that will be needed. We will need a resource group, an app service plan and then we can setup the app service. The PHP app we will be running is named Exercise Of The Day (EOTD) for short so our resources will use EOTD. Use the following steps to set all of this up.
Note the loginServer from the output. This is the FQDN of the registry. Normally we would need this, admin enabled, and the password to log into the registry. In this scenario we won’t need admin enabled or the password because we will be adding a connection to Azure DevOps and the pipelines will handle pushing to and pulling the image from the registry.
When it’s all done you should see the following resources in the new resource group:
Next, we will need to build an application and a container image.
This will be a short
post and this one is mostly for me so I can easily find this information in the
future when I need it again. 🙂
Recently I was
containerizing some PHP websites that use Composer. If you are not familiar
with Composer but you are working with PHP, you will run across it at some
point. Composer is a dependency package manager for PHP. Composer manages
(install/update) any required libraries and dependencies needed for your PHP
To use Composer you must first declare the libraries and dependencies in a composer.json file in your site directory and then you would run Composer and it will do its magic. For more information on Composer visit: https://getcomposer.org/doc/00-intro.md
Back to my task, I
needed to install Composer in the containers I was building and run it to
install all the dependencies. I needed these actions in the Dockerfile so it
would all happen during the container build. After some research on Composer I
was able to pull something together. Here is the syntax that I ended up putting
in the Dockerfile:
# Install Composer
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
# Set working directory for composer (Contains the composer.json file)
# Run Composer
RUN composer install
Note: I placed the above code at the end of the
Dockerfile ensuring Apache, PHP etc was all in place first.
Lately I have been hearing a lot about a solution named Rancher in the Kubernetes space. Rancher is an open source Kubernetes Multi-Cluster Operations and Workload Management solution. You can learn more about Rancher here: https://www.rancher.com.
In short you can use
Rancher to deploy and manage Kubernetes clusters deployed to Azure, AWS, GCP
their managed Kubernetes offerings like GCE, EKS, AKS or even if you rolled
your own. Rancher also integrates with a bunch of 3rd party solutions for
things like authentication such as Active Directory, Azure Active Directory,
Github, and Ping and logging solutions such as Splunk, Elasticsearch, or a
opened up for some Rancher/Kubernetes/Docker training so I decided to go. The
primary focus was on Rancher while also covering some good info on Docker and
Kubernetes. This was really good training with a lot of hands on time, however
there was one problem with the labs. The labs had instructions and setup
scripts ready to go to run Rancher local on your laptop or on AWS via
Terraform. There was nothing for Azure.
I ended up getting
my Rancher environment running on Azure but it would have been nice to have
some scripts or templates ready to go to spin up Rancher on Azure. I did find
some ARM templates to spin up Rancher but they deployed an old version and it
was not clear in the templates on where they could be updated to deploy the new
version of Rancher. I decided to spend some time building out a couple of ARM
templates that can be used to quickly deploy Rancher on Azure and add a
Kubernetes host to Rancher. In the ARM template I pulled together it pulls the
Rancher container from Docker Hub so it will always deploy the latest version.
In this blog post I will spell out the steps to get your Rancher up and running
in under 15 minutes.
The repository consists of ARM templates for deploying Rancher and a host VM for Kubernetes. NOTE: These templates are intended for labs to learn Rancher. They are not intended for use in production.
In the repo ARM Template #1 named RancherNode.JSON will deploy an Ubuntu VM with Docker and the latest version of Rancher (https://hub.docker.com/r/rancher/rancher) from Docker Hub. ARM Template #2 named RancherHost.JSON will deploy an Ubuntu VM with Docker to be used as a Kubernetes host in Rancher.
RancherNode.JSON ARM template to your Azure subscription through “Template
Deployment” or other deployment method. You will be prompted for the
following info shown in the screenshot:
RancherHost.JSON ARM template to your Azure subscription through “Template
Deployment” or other deployment method. Note that that should deploy this
into the same Resource Group that you deployed the Rancher Node ARM template
into. You will be prompted for the following info shown in the screenshot:
After the Rancher
Node and Rancher Host ARM templates are deployed you should see the following
resources in the new Resource Group:
Next navigate the
Rancher portal in the web browser. The URL is the DNS name of the Rancher Node
VM. You can find the DNS name by clicking on the Rancher Node VM in the Azure
portal on the overview page. Here is an example of the URL:
The Rancher portal
will prompt you to set a password. This is shown in the following screenshot.
After setting the
password the Rancher portal will prompt you for the correct Rancher Server URL.
This will automatically be the Rancher Node VM DNS name. Click Save URL.
You will then be
logged into the Rancher portal. You will see the cluster page. From here you
will want to add a cluster. Doing this is how you add a new Kubernetes cluster
to Rancher. In this post I will show you how to add a cluster to the Rancher
Host VM. When it’s all said and done Rancher will have successfully deployed
Kubernetes to the Rancher Host VM. Note that you could add a managed Kubernetes
such as AKS but we won’t do that in this blog. I will save that for a future
Click on Add Cluster
Under “From my
own existing nodes” Click on custom, give the cluster a name and click
Next check all the
boxes for the Node Options since all the roles will be on a single Kubernetes
cluster. Copy the code shown at the bottom of the page, click done and run the
code on the Rancher Host.
In order to run the
code on the Rancher Host you need to SSH in and run it from there. To do this
follow these steps:
In the Azure Portal, from within the resource group click on the Rancher Host VM.
On the Overview page click on Connect.
Copy “ssh firstname.lastname@example.org” from the Connect to virtual machine pop up screen.
Open a terminal in either Azure cloud shell or with something like a terminal via VS Code and past the “ssh email@example.com” in.
Running the code
will look like this:
When done you can
run Docker PS to see that the Rancher agent containers are running.
In the Rancher
portal under clusters you will see the Rancher host being provisioned
The status will
change as Kubernetes is deployed.
Once it’s done
provisioning you will see your Kubernetes cluster as Active.
From here you can
see a bunch of info about your new Kubernetes cluster. Also notice that you
could even launch Kubectl right from hereand start running commands! Take some
time to click around to see all the familiar stuff you are used to working with
in Kubernetes. This is pretty cool and simplifies the management experience for
If you want to add
more nodes or need the configuration code again just click the ellipsis button
In Edit Cluster you
can change the cluster name, get and change settings and copy the code to add
more VMs to the cluster.
That’s the end of
this post. Thanks for reading. Check back for more Azure, Kubernetes, and
Rancher blog posts.