Pipeline

The nine stages between a commit and a running service.

Every commit runs the same nine stages in the same order. A failure at any stage stops the release, so nothing reaches this server without compiling cleanly and passing its tests first.

  1. Checkout

    Pulls the commit that triggered the build from GitHub.

    checkout scm
  2. Environment check

    Prints the JDK and Gradle versions so the log records exactly what built this release.

    ./gradlew task03Info
  3. Compile

    Turns the Java sources into class files. Fails fast on any syntax or type error.

    ./gradlew clean compileJava
  4. Dependency report

    Writes the resolved runtime dependency tree and archives it with the build.

    ./gradlew :app:dependencies
  5. Unit tests

    Runs the JUnit 5 suite. A single failing assertion stops the release here.

    ./gradlew test
  6. Coverage

    Generates the JaCoCo report so test depth is visible, not assumed.

    ./gradlew jacocoTestReport
  7. Package

    Builds the versioned distribution archive containing the app and every dependency.

    ./gradlew distTar
  8. Deploy

    Extracts the archive into a new timestamped release directory and restarts the service.

    sudo task-03-deploy.sh
  9. Smoke test

    Polls the health endpoint until the new release answers, so a broken deploy is caught immediately.

    curl /health

Why the order matters

Cheap checks run before expensive ones. Compilation fails in seconds; packaging and deployment take far longer. Putting the tests ahead of packaging means a broken change is rejected before any artifact is built for it.