Pipeline optimization: single-stage Dockerfile + gem cache #187

Closed
opened 2026-06-09 12:13:26 +00:00 by ldraney · 0 comments
Owner

Type

Feature

Lineage

Standalone — follows from #185 DORA metrics analysis.

Repo

landscaping-assistant

User Story

As a developer, I want faster CI builds so I spend less time waiting for pipelines.

Context

DORA pipeline timing (PR #186) identified two main bottlenecks:

  1. Kaniko multi-stage build does two rootfs unpacks (4m49s of 5m23s)
  2. bundle-install fetches 153 gems from scratch every pipeline run (~90s)

Description

  • Single-stage Dockerfile eliminates the second rootfs unpack (~1m30s savings)
  • PVC-backed gem cache persists vendor/bundle across pipeline runs (~60-80s savings)
  • Restructure docs/dora.md → docs/dora/pipeline-timing.md for future DORA expansion

File Targets

  • Dockerfile (modified)
  • .woodpecker.yaml (modified)
  • docs/dora.mddocs/dora/pipeline-timing.md (renamed)

Feature Flag

None.

Acceptance Criteria

  • Single-stage Dockerfile builds successfully in Kaniko
  • Non-root rails user preserved in production image
  • Gem cache PVC config documented for infra setup
  • docs/dora/ directory created for future metrics

Test Expectations

No new tests. Existing specs validate the app works. Docker build verified by CI pipeline.

Constraints

  • Gem cache PVC requires separate pal-e-platform infra work (PVC creation + Woodpecker server config)
  • Single-stage image is ~200MB larger than multi-stage (includes build tools)

Checklist

  • Single-stage Dockerfile implemented
  • Gem cache config added to .woodpecker.yaml
  • PVC creation instructions in inline YAML comment
  • Docs restructured into docs/dora/
  • #185 — DORA metrics (parent analysis)
  • PR #186 — original DORA doc
### Type Feature ### Lineage Standalone — follows from #185 DORA metrics analysis. ### Repo landscaping-assistant ### User Story As a developer, I want faster CI builds so I spend less time waiting for pipelines. ### Context DORA pipeline timing (PR #186) identified two main bottlenecks: 1. Kaniko multi-stage build does two rootfs unpacks (4m49s of 5m23s) 2. bundle-install fetches 153 gems from scratch every pipeline run (~90s) ### Description - Single-stage Dockerfile eliminates the second rootfs unpack (~1m30s savings) - PVC-backed gem cache persists vendor/bundle across pipeline runs (~60-80s savings) - Restructure docs/dora.md → docs/dora/pipeline-timing.md for future DORA expansion ### File Targets - `Dockerfile` (modified) - `.woodpecker.yaml` (modified) - `docs/dora.md` → `docs/dora/pipeline-timing.md` (renamed) ### Feature Flag None. ### Acceptance Criteria - [ ] Single-stage Dockerfile builds successfully in Kaniko - [ ] Non-root rails user preserved in production image - [ ] Gem cache PVC config documented for infra setup - [ ] docs/dora/ directory created for future metrics ### Test Expectations No new tests. Existing specs validate the app works. Docker build verified by CI pipeline. ### Constraints - Gem cache PVC requires separate pal-e-platform infra work (PVC creation + Woodpecker server config) - Single-stage image is ~200MB larger than multi-stage (includes build tools) ### Checklist - [x] Single-stage Dockerfile implemented - [x] Gem cache config added to .woodpecker.yaml - [x] PVC creation instructions in inline YAML comment - [x] Docs restructured into docs/dora/ ### Related - #185 — DORA metrics (parent analysis) - PR #186 — original DORA doc
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
ldraney/landscaping-assistant#187
No description provided.