
Master OpenShift 4.20 and Docker from scratch, building images, using Docker Compose, and deploying Python, Java, and PostgreSQL apps to production with GitLab scripts.
Docker containers package an application with its libraries and configuration to run identically anywhere, solving the works on my machine problem and delivering faster, more predictable development than virtual machines.
Explore how Kubernetes clusters, pods, nodes, and deployments automate container orchestration with self-healing and rolling updates, while services provide stable access to pods in OpenShift foundation.
OpenShift is a Kubernetes-based platform that adds tools around it, enforces security by default and standardizes deployments, making Kubernetes easier and production-ready for enterprises through simple workflows.
Explore Windows virtualization as a prerequisite for running Docker, WSL, and Hyper-V, and OpenShift local environments, and learn to verify and enable it via Task Manager and BIOS notes.
Explore optional Hyper-V for local OpenShift setups, with OpenShift Sandbox or WSL alternatives; learn Windows prerequisites and how to enable Hyper-V via admin PowerShell and restart.
Determine if Docker is required for OpenShift and learn how to create container images and Dockerfiles to package applications for OpenShift, noting Docker steps are optional for production scenarios.
Install Docker Desktop on Windows, choosing WSL or Hyper-V, ensure virtualization is enabled and RAM is at least four gigabytes, and run WSL --install as administrator.
Learn Linux Docker installation across distributions, including Ubuntu, Debian, and Fedora, with commands to install Docker engine, start and enable the service, remove old versions, and verify the version.
Run your first docker container, verify docker is active, and learn how images are downloaded from docker hub, container naming, and terminal-based inspection.
Learn to manage docker containers and images with commands like docker ps, docker ps -a, docker logs, docker container stop, start, restart, and rm, and docker image rm.
Build a minimal Python Flask app inside a Docker image using a Python 3.12-slim base, copy source, install dependencies, expose port 5000, and view hello world.
Discover how Docker image layers form from base images through run, copy, and add commands, and why Dockerfile order and caching affect build performance and immutability.
Compare OpenShift local and sandbox permissions, showing CRC's cluster admin access and the sandbox's project-scoped limits that restrict namespaces and cluster-wide changes.
Install OpenShift local on Windows, Linux, or Mac; meet hardware requirements; run crc setup and crc start with a pull secret; compare with OpenShift sandbox's 30-day trial.
Increase crc disk size to prevent OpenShift local out-of-disk-space errors by setting disk-size to 60 gigabytes, then restart and verify with crc config view.
Explore OpenShift Sandbox to run a free 30-day cloud cluster for development, featuring a preconfigured environment and optional guided tour, accessible via discoverprogramming-dev.
Master the oc command line interface to manage an OpenShift cluster from the terminal, and learn to use the oc binary on Windows, Linux, or macOS for scripting.
Install and use git bash on Windows to run unix-like commands and automate deployment with .sh scripts alongside OpenShift tools like oc, within Visual Studio Code.
Discover how OpenShift projects, as enhanced namespaces, isolate resources, provide access control, quotas, and project specific settings for dev, test, and more.
Create a new OpenShift project using the command line or the web interface, with optional description and display name metadata, noting sandbox permissions and future discussion of the -dev suffix.
Apply environment suffixes like -dev, -test, and -prod to OpenShift project names to clearly separate environments and support safer access control and CICD automation.
Explore how builds turn source code into container images, how deployments manage replicas, how pods run, how services expose pods, and how config maps inject runtime configuration.
OpenShift deployments and deployment configs are high-level abstractions that auto-create pods, replica sets, and replication controllers, enabling continuous monitoring and focusing on application definition.
OpenShift automates pod management via deployments and deployment configs, which create replica sets and replication controllers behind the scenes, with replica sets offering advanced selectors for scalable deployment management.
Explains how to use oc new-app to deploy from a git url, image, or path, with options like --strategy, --source-secret, --name, --env, and --context-dir for contexts, including branch via hash.
Deploy a flask app on OpenShift using Docker strategy, specifying the repository, branch feat/1, and a context dir flask-api to build and expose via a route.
Learn how OpenShift image streams track image tags and metadata, point to internal or external registries, and trigger automatic builds or deployments when a new image version becomes available.
Learn to use oc get to list resources like pods and deployments, format output as YAML or JSON, and use oc describe for pod details with grep for focused searches.
switch to branch feat/2, patch the BuildConfig to that ref, and trigger a new build with oc start-build in OpenShift 4.20, while enabling production logging with waitress.
Master the oc logs command line interface in OpenShift 4.20 to fetch pod, deployment, and build config logs, control output with --tail, --since, and --follow, and view real-time updates.
Learn how to remove resources in an OpenShift project with oc delete, including deployment, service, build config, and image streams, using flags and a .sh script for automated cleanup.
Deploy your app from git using the cluster UI by importing from git, selecting a docker file with context /flask-api, enabling webhook triggers, and exposing port 5000 via a route.
Create a Docker Hub repository and push a built image by logging in, tagging as discoverprogramming/openshift-from-zero:flask-api-1, and using docker push with --push, and review tags and the docker pull command.
Deploy an application from a Docker Hub image using OpenShift's oc new-app, manage image streams, and secure production deployments with private repositories and secrets.
Deploy from an image stream with oc import-image by specifying --from and --confirm, import a docker hub image, then deploy via oc new-app to expose a route.
Deploy a PostgreSQL database from an internal OpenShift image stream in the OpenShift namespace, configure user, password, and db, and verify access via port-forwarding.
Explain how OpenShift's S2i (source to image) builds runnable container images from application source code using a predefined builder image, pulling from Git and creating deployable images without Dockerfiles.
Deploy a python app on OpenShift 4.20 using source to image with a ready image, set startup file via app_file to main.py, and address port mismatch between 5000 and 8080.
Deploy a source-to-image application from the OpenShift web console by selecting a builder image Python, setting main.py and port 8080, then create and test a route for the flask-api-c pod.
deploy an application from the command line using oc new-app with a python image stream tag 3.12-minimal-ubi9 and a GitLab repository on the feat/5 branch for s2i deployment.
Learn how config maps and secrets provide configuration data to applications in Kubernetes and OpenShift, enabling runtime configuration changes without rebuilding images, and how secrets safeguard sensitive values.
Create a config map with oc create configmap using --from-literal, --from-file, or --from-env-file, then edit or create via the web console’s form or YAML view, including data and binary data.
Learn to inspect OpenShift config maps from the CLI, view data and binary data with oc describe, and export as yaml or jsonpath for variables like app and prod.
Modify a config map from the CLI with oc edit, edit the data section to set prod to no, and save to apply the change.
Inject config map based environment variables into an OpenShift deployment using oc set env, updating deployment YAML to use a lowercase app_version and verify via pod restarts and logs.
Create a config map from a file using the oc create config map command with --from-file, using relative paths and supporting multiple files like config.yaml and config-test.yaml for deployment mounting.
Create a configmap from a folder with oc create configmap --from-file, adding files such as application.properties and config.yaml. Manage LF and CRLF line endings to prevent script and OpenShift issues.
Explore how OpenShift volumes store data outside the container image to persist across pods, with temporary and persistent options, including config maps, secrets, and persistent volume claims.
Mount the config.yaml from the config map as a single-file volume to the flask-api-b deployment at /opt/app-root/src/config.yaml. Update the config map and restart the rollout to apply changes.
Learn how to mount a whole config map folder as a volume in OpenShift, create the folder automatically, manage multiple volumes, and refresh deployments to access the config files.
Learn to access a pod's terminal from the command line using oc rsh or oc exec, with -i and -t to enter bash.
Remove and modify volumes in OpenShift 4.20 using the CLI and web console: use oc set volume --remove --name flask-api-b-second-volume, or edit the deployment with oc edit or oc patch.
Create and manage OpenShift secrets with oc create secret, explore docker registry, generic, and TLS types, and learn to view and decode base64 encoded secret data.
deploy an app from a private Docker Hub image on OpenShift using oc new-app and image pull secrets, and link the secret to the default service account.
Learn to replace plain text database credentials by creating a postgresql-credentials secret in OpenShift, storing POSTGRESQL_DATABASE, POSTGRESQL_USER, and POSTGRESQL_PASSWORD securely for deployments.
Deploy postgresql in OpenShift using the postgresql-credentials secret to populate environment variables, then verify the setup with port-forward and the secret mapping in YAML.
Deploy a private gitlab repository to OpenShift 4.20 with docker strategy, using a gitlab-secret secret, and exposing a route via CLI or cluster UI.
Hello!
as part of this course we will be working with OpenShift 4.20.5.
There are actually no special prerequisites for this course, apart from internet access and a willingness to learn :).
All topics are explained as accurately as possible to avoid generating any additional questions. But - if anything is unclear, requires further clarification, or if a new lecture needs to be added, you are more than welcome to leave a comment under the course or contact me directly via private message.
All materials (scripts, deployed applications) are available in the resources under lectures, provided as links to GitLab repositories.
There are two ways to work with OpenShift during the course:
OpenShift Sandbox, which does not require installing the entire cluster infrastructure on your local machine
OpenShift Local, where we install the cluster locally on your computer — the system requirements for this option are discussed in the course
Throughout the course, we focus on practical application deployment. We don’t just go through dry examples — we actually deploy real applications written in Python and Java.
The applications themselves do not contain complex business logic, as the goal of this course is not to teach programming in these languages, but to learn how to work with OpenShift and containerized applications.
During the learning process, questions will naturally arise, and some topics discussed at a given moment may be difficult to understand. Don’t worry about this — throughout the course, certain topics are intentionally skipped (with a clear note that they will be covered later) in order to focus on other elements first.
In the end, everything should come together into a coherent whole and give you the ability to navigate and work confidently with OpenShift.