Featured resource
2025 Tech Upskilling Playbook
Tech Upskilling Playbook

Build future-ready tech teams and hit key business milestones with seven proven plays from industry leaders.

Check it out
  • Lab
    • Libraries: If you want this lab, consider one of these libraries.
    • Cloud
Google Cloud Platform icon
Labs

Installing and Configuring Flux with GitHub

This lab introduces the steps necessary steps for installing Flux and configuring it to work with a student repository in GitHub. The student will need their own GitHub account to fork a sample repository, and this lab will spin up a Kubernetes cluster to enable the student to install and configure Flux.

Google Cloud Platform icon
Lab platform
Lab Info
Level
Beginner
Last updated
Sep 18, 2025
Duration
45m

Contact sales

By filling out this form and clicking submit, you acknowledge our privacy policy.
Table of Contents
  1. Challenge

    Create a GitHub Repository Under Your Own Account

    To create a repository on GitHub you must log in to your own account, and then you can create a repository with the YAML files you require. Or you can find the linuxacademy/content-gitops repository and fork it. Once you create your own version of that repository, examine the YAML files in the namespaces and workloads folders.

  2. Challenge

    Deploy Flux Into Your Cluster

    To check whether fluxctl is installed, enter:

    $ fluxctl version
    

    If fluxctl did not install automatically, you may enter the following command to install it:

    $ sudo wget https://github.com/fluxcd/flux/releases/download/1.25.4/fluxctl_linux_amd64 -O /usr/bin/fluxctl && sudo chmod +x /usr/bin/fluxctl
    

    Create a namespace for Flux:

    $ kubectl create ns flux
    

    Set the GHUSER environment variable:

    $ export GHUSER=[Your GitHub Handle]
    

    Deploy Flux using the fluxctl command:

    $ fluxctl install 
    --git-user=${GHUSER} 
    --git-email=${GHUSER}@users.noreply.github.com 
    [email protected]:${GHUSER}/content-gitops 
    --git-path=namespaces,workloads 
    --namespace=flux | kubectl apply -f -
    
  3. Challenge

    Verify The Deployment and Obtain the RSA Key

    Verify the Flux deployment:

    $ kubectl -n flux rollout status deployment/flux
    

    Obtain the Flux RSA key created by fluxctl:

    $ fluxctl identity --k8s-fwd-ns flux
    

    Copy off the RSA key to implement in GitHub.

  4. Challenge

    Implement the RSA Key in GitHub

    Use the GitHub User Interface to Add the RSA Key obtained as a Deploy Key in GitHub.

  5. Challenge

    Use the fluxctl sync Command to Synchronize the Cluster with the Repository

    Use fluxctl to sync the cluster with the repository:

    $ fluxctl sync --k8s-fwd-ns flux
    

    Then check the existence of the lasample namespace:

    $ kubectl get namespaces
    

    Finally check that the Nginx deployment is running:

    $ kubectl get pods --all-namespaces
    
About the author

Pluralsight Skills gives leaders confidence they have the skills needed to execute technology strategy. Technology teams can benchmark expertise across roles, speed up release cycles and build reliable, secure products. By leveraging our expert content, skill assessments and one-of-a-kind analytics, keep up with the pace of change, put the right people on the right projects and boost productivity. It's the most effective path to developing tech skills at scale.

Real skill practice before real-world application

Hands-on Labs are real environments created by industry experts to help you learn. These environments help you gain knowledge and experience, practice without compromising your system, test without risk, destroy without fear, and let you learn from your mistakes. Hands-on Labs: practice your skills before delivering in the real world.

Learn by doing

Engage hands-on with the tools and technologies you’re learning. You pick the skill, we provide the credentials and environment.

Follow your guide

All labs have detailed instructions and objectives, guiding you through the learning process and ensuring you understand every step.

Turn time into mastery

On average, you retain 75% more of your learning if you take time to practice. Hands-on labs set you up for success to make those skills stick.

Get started with Pluralsight