Skip to content

Contact sales

By filling out this form and clicking submit, you acknowledge our privacy policy.
  • Labs icon Lab
  • A Cloud Guru
Google Cloud Platform icon
Labs

Using Pull Requests For Release Gating

A part of developing your GitOps skillset, this lab introduces the student to GitHub Actions Workflow and challenges the student to build and push a container to Docker Hub. The application container may then be deployed to Kubernetes Clusters through Flux and the Deployment YAML required.

Google Cloud Platform icon
Labs

Path Info

Level
Clock icon Beginner
Duration
Clock icon 45m
Published
Clock icon Feb 13, 2020

Contact sales

By filling out this form and clicking submit, you acknowledge our privacy policy.

Table of Contents

  1. Challenge

    Fork the linuxacademycontent/gitops Repo in GitHub

    Use your personal account to fork the course repo into your own GitHub Account.

  2. Challenge

    Create a Docker Hub Folder to Receive the Pushed Container Images

    Set up a folder for the container images in Docker Hub.

  3. Challenge

    Enable Actions WorkFlows In The Forked Repository

    Go the to Actions tab and enable workflows.

    NOTE: You will also need to add a secret to the repo for the Docker Hub Password. Use Settings and Secrets to add the password so the docker login in the workflow will push the image to your dockerhub registry.

  4. Challenge

    Edit the Workflow to Push Your Container Images to Your Docker Hub Registry

    Edit the workflow provided with your Docker Hub information.

    1. You must add a DOCKERPW secret to your repo with the docker hub password for your dockerhub account. This is done in GitHub under Settings->Secrets

    2. You will need to edit the actions workflow to replace the [your docerhub userneme] clause with your actual dockerhub username.

    This configure the actions workflow to push the container image to your docker hub registery.

    You can test this on a push, command by just changing the python program a bit and watching the actions workflow run.

    Once you have the workflow running, you can then edit the workflow to run for a pull request instead of a push.

    Change the event that fires the workflow from push to pull_request.

  5. Challenge

    Change The Python Application And Open A Pull Request

    Create a feature branch. Change the Python application, then commit the change. Then create a pull request and merge the change in. Examine the workflow actions run afterward and verify the container was pushed to the Docker Hub Registry.

The Cloud Content team comprises subject matter experts hyper focused on services offered by the leading cloud vendors (AWS, GCP, and Azure), as well as cloud-related technologies such as Linux and DevOps. The team is thrilled to share their knowledge to help you build modern tech solutions from the ground up, secure and optimize your environments, and so much more!

What's a lab?

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.

Provided environment for hands-on practice

We will provide the credentials and environment necessary for you to practice right within your browser.

Guided walkthrough

Follow along with the author’s guided walkthrough and build something new in your provided environment!

Did you know?

On average, you retain 75% more of your learning if you get time for practice.

Start learning by doing today

View Plans