packer: fix build scripts, packerlib update.

There were some hardcoded values left in there, and the remote caching
wasn't working right.

The ubuntu-board-gen tool now produces the right output file
name.
This commit is contained in:
2023-04-12 12:50:11 -07:00
parent 91a631ef4f
commit be216aefe5
8 changed files with 31 additions and 123 deletions

View File

@@ -1,4 +1,4 @@
load("@io_bazel_rules_go//go:def.bzl", "go_library")
load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
go_library(
name = "packerlib",
@@ -13,3 +13,9 @@ go_library(
visibility = ["//visibility:public"],
deps = ["@in_gopkg_yaml_v2//:yaml_v2"],
)
go_test(
name = "packerlib_test",
srcs = ["ubuntu_test.go"],
embed = [":packerlib"],
)

View File

@@ -61,7 +61,6 @@ func (spec UbuntuBoardSpec) JSONPath(base string) string {
dest := spec.ImageName
ext := filepath.Ext(dest)
if ext != "" {
ext = "." + ext
dest = strings.TrimSuffix(dest, ext)
}