Skip to content
This repository was archived by the owner on Apr 15, 2026. It is now read-only.

feat(labctl): add images CLI foundation - #29

Merged
jmgilman merged 7 commits into
masterfrom
joshuagilman/hom-19-labctl-images-cli-foundation
Dec 20, 2025
Merged

feat(labctl): add images CLI foundation#29
jmgilman merged 7 commits into
masterfrom
joshuagilman/hom-19-labctl-images-cli-foundation

Conversation

@jmgilman

Copy link
Copy Markdown
Collaborator

Summary

Implements the CLI foundation for labctl images as specified in HOM-19:

  • Go module at tools/labctl/ with Go 1.23+ and Cobra CLI
  • images subcommand with stubs for sync, validate, list, prune, upload
  • Config package for parsing ImageManifest YAML with full validation
  • Credentials package for environment variables and SOPS-encrypted file resolution
  • Store package with S3-compatible client (iDrive e2) using AWS SDK v2

Key Features

  • Functional options pattern for configuration (WithContext)
  • Interface-based mocking for comprehensive unit tests
  • Table-driven tests with testify/assert and testify/require
  • golangci-lint configuration with security linters enabled

Test Coverage

Package Coverage
internal/config 94.2%
internal/credentials 84.2%
internal/store 81.0%

Test plan

  • go build ./tools/labctl succeeds
  • labctl images --help shows all subcommands
  • All 45 unit tests pass with go test ./... -race
  • golangci-lint run ./... reports 0 issues
  • go vet ./... passes

Closes HOM-19

🤖 Generated with Claude Code

jmgilman and others added 3 commits December 19, 2025 19:59
Implement the foundational infrastructure for the labctl images CLI tool:

- Go module at tools/labctl/ with Cobra CLI scaffolding
- images subcommand with sync, validate, list, prune, upload stubs
- Config package for parsing ImageManifest YAML with validation
- Credentials package for env vars and SOPS file resolution
- Store package with S3-compatible client for iDrive e2

All packages include unit tests with no external dependencies.

Closes HOM-19

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@linear

linear Bot commented Dec 20, 2025

Copy link
Copy Markdown

jmgilman and others added 4 commits December 19, 2025 20:43
Runs on push to master and PRs when tools/labctl/** changes:
- Format check (gofmt)
- Go vet
- golangci-lint
- Tests with race detection

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v7 is required for golangci-lint v2.x support.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Replace 'disable-all: true' with 'default: none'
- Replace 'exclude-use-default: false' with 'exclusions.presets: []'

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@jmgilman
jmgilman merged commit ca55c80 into master Dec 20, 2025
1 check passed
@jmgilman
jmgilman deleted the joshuagilman/hom-19-labctl-images-cli-foundation branch December 20, 2025 04:54
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant