mirror of
https://github.com/TecharoHQ/anubis.git
synced 2025-09-09 04:39:11 -04:00
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>
This commit is contained in:
parent
62e20a213a
commit
3438595f32
@ -123,10 +123,10 @@ func parseImageList(imageList string) ([]image, error) {
|
|||||||
// reg.xeiaso.net/techaro/anubis:latest
|
// reg.xeiaso.net/techaro/anubis:latest
|
||||||
// repository: reg.xeiaso.net/techaro/anubis
|
// repository: reg.xeiaso.net/techaro/anubis
|
||||||
// tag: latest
|
// tag: latest
|
||||||
parts := strings.SplitN(img, ":", 2)
|
index := strings.LastIndex(img, ":")
|
||||||
result = append(result, image{
|
result = append(result, image{
|
||||||
repository: parts[0],
|
repository: img[:index],
|
||||||
tag: parts[1],
|
tag: img[index+1:],
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user