upaas/internal/domain/types.go
clawbot 002fdd87a7
All checks were successful
Check / check (pull_request) Successful in 11m24s
rework: address review feedback on PR #126
Changes per sneak's review:
- Delete docker-compose.yml, add example stanza to README
- Define custom domain types: ImageID, ContainerID, UnparsedURL
- Use custom types in all function signatures throughout codebase
- Restore imageID parameter (as domain.ImageID) in deploy pipeline
- buildContainerOptions now takes ImageID directly instead of
  constructing image tag from deploymentID
- Fix pre-existing JS formatting (prettier)

make check passes with zero failures.
2026-02-23 11:54:05 -08:00

17 lines
641 B
Go

// Package domain defines domain-specific string types for compile-time safety.
// Using named types prevents accidentally passing the wrong string argument
// (e.g. a container ID where an image ID is expected).
package domain
// ImageID is a Docker image identifier (ID or tag).
type ImageID string
// ContainerID is a Docker container identifier.
type ContainerID string
// UnparsedURL is a URL stored as a plain string without parsing.
// Use this instead of string when the value is known to be a URL
// but should not be parsed into a net/url.URL (e.g. webhook URLs,
// compare URLs from external payloads).
type UnparsedURL string