Skip to content

PE-8711: switch internal Earthfile base from Alpine to Ubuntu#605

Open
vipsharm wants to merge 1 commit into
mainfrom
PE-8711
Open

PE-8711: switch internal Earthfile base from Alpine to Ubuntu#605
vipsharm wants to merge 1 commit into
mainfrom
PE-8711

Conversation

@vipsharm
Copy link
Copy Markdown
Contributor

Summary

Switches the internal Earthfile targets that previously consumed $ALPINE_IMG to use the existing +ubuntu target. The published +alpine / +alpine-all targets, earthly/dind:alpine-*, and golang:*-alpine are intentionally left unchanged — they are external/upstream.

Changes

Targets switched to +ubuntu (which already handles the FIPS variant via $SPECTRO_PUB_REPO/third-party/ubuntu-fips:22.04):

  • File-level base (FROM at top of Earthfile)
  • build-provider-images
  • install-k8s
  • download-sbctl
  • third-party

UDC renamed: BASE_ALPINEBASE_UBUNTU (definition + 2 callers). Body unchanged — update-ca-certificates is portable.

Package installs added (Ubuntu base does not include what Alpine had baked in):

  • build-provider-images: jq (used to parse k8s_version.json)
  • download-sbctl: curl ca-certificates (used to fetch sbctl tarball)
  • third-party: upx-ucl (used by the UPX UDC)

Out of scope (deliberately not touched):

  • +alpine / +alpine-all — still publishes gcr.io/spectro-dev-public/canvos/alpine:$ALPINE_TAG; external consumers may depend on it.
  • earthly/dind:alpine-3.19-docker-25.0.5-r0 (cloud-image, aws-cloud-image) — upstream Earthly DinD runtime.
  • $SPECTRO_PUB_REPO/third-party/golang:${GOLANG_VERSION}-alpine (go-deps) — upstream Go build image.

Validation

  • earthly ls parses the Earthfile cleanly; all 40 targets resolve.
  • Static review only — full builds still need to be exercised by CI/maintainer.

Test plan

  • CI green for +build-provider-images across all k8s distributions.
  • CI green for +install-k8s, +download-sbctl, +third-party.
  • FIPS path validated (FIPS_ENABLED=true) — +ubuntu picks the ubuntu-fips:22.04 variant.
  • Confirm published gcr.io/spectro-dev-public/canvos/alpine:$ALPINE_TAG is still produced by +alpine-all.

Switch the file-level base and the targets that consumed $ALPINE_IMG
(build-provider-images, install-k8s, download-sbctl, third-party) to
use the existing +ubuntu target, which already handles the FIPS
variant. Rename the BASE_ALPINE UDC to BASE_UBUNTU; its body
(update-ca-certificates) is portable between distros.

Add apt-get installs for packages the Alpine image had baked in:
- build-provider-images: jq (used to read k8s_version.json)
- download-sbctl: curl ca-certificates (used to fetch sbctl tarball)
- third-party: upx-ucl (used by the UPX UDC)

The +alpine / +alpine-all publish targets, earthly/dind:alpine, and
golang:*-alpine remain unchanged — they are external/upstream and
outside the scope of this switch.

Validated with `earthly ls` (all 40 targets resolve).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant