Search⌘ K
AI Features

Continuous Delivery with Flux

Explore how to manage containerized workloads on Kubernetes using Flux for continuous delivery. Understand the process of updating applications by committing code changes, building and pushing container images, then deploying new versions automatically with GitOps. This lesson guides you through updating the desired state and inspecting runtime cluster states to ensure smooth application version transitions.

Managing workloads with Flux

Now that we've configured Flux on a Kubernetes cluster, we can walk through the end-to-end process for managing containerized workloads with GitOps. For developers, releasing a new application version is as simple as performing a Git commit that updates the desired state once their changes are packaged into a container image.

Normally, the new container image is created by a continuous integration pipeline triggered when a developer pushes changes to the application source code. Since CI is outside the scope of this course, we'll need to manually build a container image after updating the sample Python application and push it to Docker Hub.

Update the sample application

We'll start by making a small change to our sample Python application that will provide us with a new version of the application we would like to deploy on the cluster. Within the first interactive widget below, navigate to the /system/app/app.py file containing our sample application. Within the app.py file, make the following change to the application to update the message it returns:

Python 3.8
from flask import Flask
app = Flask(__name__)
@app.route("/")
def hello_world():
return 'Hello, Educative Learner! This is version 2.0'
...