From Git Repo to Docker Image: Building Your First CI Pipeline in Harness
Description and use
Building a CI pipeline in Harness in minutes: connect the repo, let the platform auto‑generate the pipeline, build, test, and push a Docker image without writing YAML.
Problem
Developers need a quick way to set up a CI pipeline that builds, tests, and pushes a Docker image without writing YAML.
Outcome
The pipeline executed in 2 min 34 s, passing 42 unit tests and successfully pushing the image to DockerHub, all without writing any YAML.
Workflow
- Connect Harness to GitHub via OAuth
- Select repository to build
- Harness scans repo and generates pipeline YAML
- Review and start first build
- Pipeline runs: Initialize, Clone, Build Intelligence, Restore cache, Build, Test, Save cache
- Add Build and Push Docker step
- Configure DockerHub connector and image tags
- Run pipeline again to build, test, and push image
Evidence
Connected a GitHub repo, built it, tested it, and pushed a tagged image to DockerHub, in about ten minutes, without writing a line of YAML.
Harness will scan the repository, determine the stages and steps it needs, generate the pipeline, and store the YAML inside the .harness directory of the repository.
The pipeline started running immediately. I could see Harness going through the generated steps: Initialize, Clone the codebase, Set up Build Intelligence, Restore the cache, Build, Test, Save the cache.
The full run took 2 minutes and 34 seconds. 42 tests passed.
- Record date: 2026-10-20T09:56:23.952Z