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
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# -> golang image used solely for building the k3d binary #
# -> built executable can then be copied into other stages #
############################################################
FROM golang:1.22.4 as builder
FROM golang:1.24.4 as builder

Check warning on line 7 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build & Release Images

The 'as' keyword should match the case of the 'from' keyword

FromAsCasing: 'as' and 'FROM' keywords' casing do not match More info: https://docs.docker.com/go/dockerfile/rule/from-as-casing/

Check warning on line 7 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build & Release Images

The 'as' keyword should match the case of the 'from' keyword

FromAsCasing: 'as' and 'FROM' keywords' casing do not match More info: https://docs.docker.com/go/dockerfile/rule/from-as-casing/
ARG GIT_TAG_OVERRIDE
WORKDIR /app
RUN mkdir /tmp/empty
Expand All @@ -14,9 +14,9 @@
#######################################################
# dind #
# -> k3d + some tools in a docker-in-docker container #
# -> used e.g. in our CI pipelines for testing #

Check warning on line 17 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build & Release Images

JSON arguments recommended for ENTRYPOINT/CMD to prevent unintended behavior related to OS signals

JSONArgsRecommended: JSON arguments recommended for ENTRYPOINT to prevent unintended behavior related to OS signals More info: https://docs.docker.com/go/dockerfile/rule/json-args-recommended/

Check warning on line 17 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build & Release Images

JSON arguments recommended for ENTRYPOINT/CMD to prevent unintended behavior related to OS signals

JSONArgsRecommended: JSON arguments recommended for ENTRYPOINT to prevent unintended behavior related to OS signals More info: https://docs.docker.com/go/dockerfile/rule/json-args-recommended/
#######################################################
FROM docker:$DOCKER_VERSION-dind as dind

Check warning on line 19 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build & Release Images

The 'as' keyword should match the case of the 'from' keyword

FromAsCasing: 'as' and 'FROM' keywords' casing do not match More info: https://docs.docker.com/go/dockerfile/rule/from-as-casing/

Check warning on line 19 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build & Release Images

The 'as' keyword should match the case of the 'from' keyword

FromAsCasing: 'as' and 'FROM' keywords' casing do not match More info: https://docs.docker.com/go/dockerfile/rule/from-as-casing/
ARG OS
ARG ARCH

Expand All @@ -40,7 +40,7 @@
# binary-only #
# -> only the k3d binary.. nothing else #
#########################################
FROM scratch as binary-only

Check warning on line 43 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build & Release Images

The 'as' keyword should match the case of the 'from' keyword

FromAsCasing: 'as' and 'FROM' keywords' casing do not match More info: https://docs.docker.com/go/dockerfile/rule/from-as-casing/

Check warning on line 43 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build & Release Images

The 'as' keyword should match the case of the 'from' keyword

FromAsCasing: 'as' and 'FROM' keywords' casing do not match More info: https://docs.docker.com/go/dockerfile/rule/from-as-casing/
# empty tmp directory to avoid errors when transforming the config file
COPY --from=builder /tmp/empty /tmp
COPY --from=builder /app/bin/k3d /bin/k3d
Expand Down
13 changes: 12 additions & 1 deletion pkg/types/fixes/fixes.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,18 @@ var fixNeeded = map[K3DFixEnv]func(runtime runtimes.Runtime) bool{
l.Log().Debugf("[autofix cgroupsv2] cgroupVersion: %d", cgroupVersion)
return cgroupVersion == 2
},
EnvFixDNS: func(_ runtimes.Runtime) bool {
EnvFixDNS: func(runtime runtimes.Runtime) bool {
runtimeInfo, err := runtime.Info()
if err != nil {
l.Log().Warnf("Failed to get runtime information: %+v", err)
return false
}

if runtimeInfo.InfoName == "colima" {
l.Log().Debug("Skipping the DNS fix on Colima.")
return false
}

return true
},
EnvFixMounts: func(_ runtimes.Runtime) bool {
Expand Down
2 changes: 1 addition & 1 deletion tools/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.22.4-alpine3.20 AS builder
FROM golang:1.24.3-alpine3.20 AS builder
ARG GIT_TAG
WORKDIR /app
COPY . .
Expand Down