diff options
| author | rayer <70722312+rayes0@users.noreply.github.com> | 2025-04-13 19:58:43 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-04-13 15:58:43 -0400 |
| commit | 3438595f32650c5e355063e70398436fd5957056 (patch) | |
| tree | 345e5f8970b37406f1c7fe220f4548d115f9a9b2 | |
| parent | 62e20a213a11bc0616d5e07a33491c801e2e1e33 (diff) | |
| download | anubis-3438595f32650c5e355063e70398436fd5957056.tar.xz anubis-3438595f32650c5e355063e70398436fd5957056.zip | |
cmd/containerbuild/main.go: fix docker tag parsing (#260)
Change the parsing of repository and tag to match the last colon. This fixes container builds when the repository already contains an earlier colon.
Signed-off-by: rayer <70722312+rayes0@users.noreply.github.com>
| -rw-r--r-- | cmd/containerbuild/main.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cmd/containerbuild/main.go b/cmd/containerbuild/main.go index 8d34a3a..e7dceae 100644 --- a/cmd/containerbuild/main.go +++ b/cmd/containerbuild/main.go @@ -123,10 +123,10 @@ func parseImageList(imageList string) ([]image, error) { // reg.xeiaso.net/techaro/anubis:latest // repository: reg.xeiaso.net/techaro/anubis // tag: latest - parts := strings.SplitN(img, ":", 2) + index := strings.LastIndex(img, ":") result = append(result, image{ - repository: parts[0], - tag: parts[1], + repository: img[:index], + tag: img[index+1:], }) } |
