Software · Beginner

Git, Docker, and CI/CD Foundations

Version a small Python service with Git, package it with Docker and Compose, and ship it through a fail-closed CI script, semantic-version releases and a practised rollback.

About this course

Every software team, whatever it builds, needs the same three habits: a truthful history of the code, a repeatable way to run it anywhere, and a release process that fails safely. This course builds those habits on one small HTTP status service that you create in the first lesson and ship in the last one. **Git (lessons 1–4).** You initialise a repository, learn the three areas (working tree, staging area, repository), branch and merge, resolve a real conflict, publish to a shared origin, run a feature-branch review workflow with a second working copy, and undo mistakes with `restore`, `reset`, `revert`, the reflog and `stash` — choosing the right tool for local versus shared history. **Docker (lessons 5–7).** You run, inspect and clean up containers, write a Dockerfile for the service with a non-root user and a built-in health check, learn how layers and the build cache behave, and define a Compose stack with PostgreSQL 16, a persistent volume and a git-ignored environment file. **CI/CD and operations (lessons 8–10).** You write `ci.sh` — lint, test, build, smoke-test, tag — as a contract that exits non-zero on the first failure, run it automatically from a versioned pre-push hook, and read the same contract expressed as a GitHub Actions workflow. You then cut `v1.0.0` and `v1.0.1` releases, promote the tested image without rebuilding, roll the service back and forward, and finish with logs, restart policies, resource limits, secrets handling, image-scanning concepts and disk hygiene. **Final project.** "Ship the service": from an empty directory you deliver a versioned repository with a feature-branch history, a Dockerfile, a Compose stack, a passing `ci.sh`, two releases, a demonstrated rollback and a short runbook — graded against a rubric and automated lab checks. Everything runs on your own lab machine `linux01`. No GitHub or GitLab account is needed: the remote is a local bare repository and CI is a script you can read in full. The course is a learning pathway toward software-delivery and platform work; it does not promise employment or any vendor certification.

Content time
9 h 55 min
Lessons
10
Certificate
Yes
on completion
Choose a career path

Lesson 1 is free. Enroll in a career path to access its full courses.

Lesson 1 is a free preview — read it without an account.

Software — the kind of infrastructure this course is practised on

Outline

Lessons

10 lessons · 9 h 55 min
  1. Lesson 1: Version control, and your first commitsFree preview

    Create a Git repository, make commits, read history and diffs, understand the three areas, and keep generated files out with .gitignore.

    55 min
  2. Lesson 2: Branching, merging and conflicts

    Develop a change on a branch, merge it back, resolve a real merge conflict, and choose between merge and rebase with safe defaults.

    1 h
  3. Lesson 3: Remotes and the feature-branch workflow

    Publish to a local bare repository acting as origin, clone it, run a feature-branch review workflow, and reconcile a rejected push.

    1 h
  4. Lesson 4: Undoing things safely

    Discard, unstage, reset, revert, recover with the reflog, and stash work in progress — choosing the safe tool for local versus shared history.

    55 min
  5. Lesson 5: Containers, and the Docker CLI mental model

    Run and inspect containers, tell images from containers, use logs, exec, ports, bind mounts and named volumes, and clean up.

    1 h
  6. Lesson 6: Building images with a Dockerfile

    Write a Dockerfile for the Python service with a non-root user and a health check, understand layers and the build cache, and tag images.

    1 h 5 min
  7. Lesson 7: Compose — the app plus PostgreSQL

    Define a two-service stack with Compose, connect the app to PostgreSQL 16 over a network, persist data in a volume, and keep secrets out of Git.

    1 h
  8. Lesson 8: CI as a contract

    Turn local checks into a fail-closed ci.sh (lint, test, build, smoke, tag), enforce it with a pre-push hook, and map it to a GitHub Actions workflow.

    1 h 5 min
  9. Lesson 9: Releases, tags and rollback

    Cut semantic-version releases with annotated tags, promote the tested image without rebuilding, deploy, and roll a Compose service back and forward.

    1 h
  10. Lesson 10: Operating containers

    Read logs, set restart policies and resource limits, handle secrets with a Compose secret, understand image scanning, and clean up disk.

    55 min

Where it leads

Part of these career paths