Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion integration/images.go
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,6 @@ func FindDockerFiles(dir, dockerfilesPattern string) ([]string, error) {
// Remove the leading directory from the path
dockerfile = dockerfile[len("dockerfiles/"):]
dockerfiles = append(dockerfiles, dockerfile)

}
return dockerfiles, err
}
Expand Down
1 change: 0 additions & 1 deletion pkg/buildcontext/tar.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ func (t *Tar) UnpackTarFromBuildContext() (string, error) {
_, err = util.UnTar(gzr, directory)

return directory, err

}

return directory, util.UnpackCompressedTar(t.context, directory)
Expand Down
2 changes: 1 addition & 1 deletion pkg/commands/copy.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ type CopyCommand struct {

func (c *CopyCommand) ExecuteCommand(config *v1.Config, buildArgs *dockerfile.BuildArgs) error {
// Resolve from
uid, gid := int64(-1), int64(-1)
var uid, gid int64
var err error
replacementEnvs := buildArgs.ReplacementEnvs(config.Env)
if c.cmd.From != "" {
Expand Down
1 change: 0 additions & 1 deletion pkg/commands/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ func runCommandWithFlags(config *v1.Config, buildArgs *dockerfile.BuildArgs, cmd
return fmt.Errorf("environment variable for secret %q not set: %s", secretId, s.Src)
}
secretData = []byte(val)
val = ""
} else {
secretData, err = os.ReadFile(s.Src)
if err != nil {
Expand Down
1 change: 0 additions & 1 deletion pkg/commands/workdir.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ func (w *WorkdirCommand) ExecuteCommand(config *v1.Config, buildArgs *dockerfile
// Only create and snapshot the dir if it didn't exist already
w.snapshotFiles = []string{}
if _, err := os.Stat(config.WorkingDir); os.IsNotExist(err) {

uid, gid, err := util.GetActiveUserGroup(config.User, "", replacementEnvs)
if err != nil {
return fmt.Errorf("getting user group: %w", err)
Expand Down
1 change: 0 additions & 1 deletion pkg/image/remote/remote.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ func RetrieveRemoteImage(image string, opts config.RegistryOptions, customPlatfo

if newRegURLs, found := opts.RegistryMaps[ref.Context().RegistryStr()]; found {
for _, registryMapping := range newRegURLs {

regToMapTo, repositoryPrefix := parseRegistryMapping(registryMapping)

insecurePull := opts.InsecurePull || opts.InsecureRegistries.Contains(regToMapTo)
Expand Down
2 changes: 1 addition & 1 deletion pkg/util/assert.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ func init() {
return
}
disabledAssertions = make(map[string]struct{})
for _, name := range strings.Split(val, ",") {
for name := range strings.SplitSeq(val, ",") {
name = strings.TrimSpace(name)
if name != "" {
disabledAssertions[name] = struct{}{}
Expand Down
1 change: 0 additions & 1 deletion pkg/util/command_util_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,6 @@ func Test_EnvReplacement(t *testing.T) {
for _, test := range testEnvReplacement {
actualPath, err := ResolveEnvironmentReplacement(test.path, test.envs, test.isFilepath)
testutil.CheckErrorAndDeepEqual(t, false, err, test.expectedPath, actualPath)

}
}

Expand Down
1 change: 0 additions & 1 deletion pkg/util/fs_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,6 @@ func extractLayer(i int, l v1.Layer, root string, cfg *FSConfig) ([]string, erro
logrus.Trace("Not including whiteout files")
continue
}

}

if err := cfg.extractFunc(root, hdr, cleanedName, tr); err != nil {
Expand Down
2 changes: 1 addition & 1 deletion pkg/util/fs_util_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -766,7 +766,7 @@ func TestExtractFile(t *testing.T) {
t.Run(tc.name, func(t *testing.T) {
tc := tc
t.Parallel()
r := ""
var r string

if tc.tmpdir != "" {
r = tc.tmpdir
Expand Down
1 change: 0 additions & 1 deletion pkg/util/transport_util_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,5 @@ func Test_makeTransport(t *testing.T) {
}
tt.check(tlsConfig, certPool, err)
})

}
}
Loading