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
6 changes: 3 additions & 3 deletions content/manuals/dhi/migration/migrate-from-doi.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ replaced by the new hardened image.
- FROM golang:1.25

+ ## Updated to use hardened base image
+ FROM dhi.io/golang:1.25-debian12-dev
+ FROM dhi.io/golang:1.25-debian13-dev
```

Note that DHI does not have a `latest` tag in order to promote best practices
Expand Down Expand Up @@ -89,13 +89,13 @@ The following example shows a multi-stage Dockerfile with a build stage and runt

```dockerfile
# Build stage
FROM dhi.io/golang:1.25-debian12-dev AS builder
FROM dhi.io/golang:1.25-debian13-dev AS builder
WORKDIR /app
COPY . .
RUN go build -o myapp

# Runtime stage
FROM dhi.io/golang:1.25-debian12
FROM dhi.io/golang:1.25-debian13
WORKDIR /app
COPY --from=builder /app/myapp .
ENTRYPOINT ["/app/myapp"]
Expand Down
8 changes: 4 additions & 4 deletions content/manuals/dhi/migration/migrate-from-ubuntu.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ replaced by the new DHI Debian image.
- FROM ubuntu/go:1.22-24.04

+ ## Updated to use hardened Debian-based image
+ FROM dhi.io/golang:1-debian13-dev
+ FROM dhi.io/golang:1.25-debian13-dev
```

To find the right tag, explore the available tags in the [DHI
Expand All @@ -74,7 +74,7 @@ contain package managers.
- && rm -rf /var/lib/apt/lists/*

+ ## DHI: Use a language-specific dev image with package manager
+ FROM dhi.io/golang:1-debian13-dev
+ FROM dhi.io/golang:1.25-debian13-dev
+ RUN apt-get update && apt-get install -y \
+ git \
+ && rm -rf /var/lib/apt/lists/*
Expand Down Expand Up @@ -105,7 +105,7 @@ The following example shows a multi-stage Dockerfile migrating from Ubuntu to DH

```dockerfile
# Build stage
FROM dhi.io/golang:1-debian13-dev AS builder
FROM dhi.io/golang:1.25-debian13-dev AS builder
WORKDIR /app

# Install system dependencies (only available in dev images)
Expand All @@ -121,7 +121,7 @@ COPY . .
RUN CGO_ENABLED=0 GOOS=linux go build -a -ldflags="-s -w" -o main .

# Runtime stage
FROM dhi.io/golang:1-debian13
FROM dhi.io/golang:1.25-debian13
WORKDIR /app

# Copy compiled binary from builder
Expand Down
6 changes: 3 additions & 3 deletions content/manuals/dhi/migration/migrate-from-wolfi.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ replaced by the new hardened image.
- FROM cgr.dev/chainguard/go:latest-dev

+ ## Updated to use hardened base image
+ FROM dhi.io/golang:1.25-alpine3.22-dev
+ FROM dhi.io/golang:1.25-alpine3.24-dev
```

Note that DHI does not have a `latest` tag in order to promote best practices
Expand All @@ -70,13 +70,13 @@ The following example shows a multi-stage Dockerfile with a build stage and runt

```dockerfile
# Build stage
FROM dhi.io/golang:1.25-alpine3.22-dev AS builder
FROM dhi.io/golang:1.25-alpine3.24-dev AS builder
WORKDIR /app
COPY . .
RUN go build -o myapp

# Runtime stage
FROM dhi.io/golang:1.25-alpine3.22
FROM dhi.io/golang:1.25-alpine3.24
WORKDIR /app
COPY --from=builder /app/myapp .
ENTRYPOINT ["/app/myapp"]
Expand Down