Skip to content

Commit 604c91d

Browse files
authored
feat(docker): upgrade base images and dependencies to DHI trixie (aron-muon#35)
* feat(docker): upgrade base images and dependencies to DHI trixie - C/C++, D, Fortran, R: Switch to dhi.io/debian-base:trixie-debian13-dev - Go: Upgrade to 1.26 via dhi.io/golang:1.26-debian13-dev - PHP: Bump 8.4.17 to 8.5.3 via DHI base image - Rust: Upgrade to 1.93 via dhi.io/rust:1.93-debian13-dev - Python: Switch to dhi.io/python:3.14-debian13, reorganize runtime libs - Node.js packages and Python requirements version bumps - Rust Cargo.toml dependency refresh - Add .editorconfig for consistent coding style * feat(docker): upgrade pip, setuptools, and packaging versions * Updated pip to version >=24.1 * Updated setuptools to version >=70 * Updated packaging to version >=24 * Ensures compatibility with newer package versions
1 parent 53e445d commit 604c91d

17 files changed

Lines changed: 297 additions & 233 deletions

.editorconfig

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
root = true
2+
3+
[*]
4+
end_of_line = lf
5+
insert_final_newline = true
6+
trim_trailing_whitespace = true
7+
charset = utf-8
8+
9+
[*.py]
10+
indent_style = space
11+
indent_size = 4
12+
max_line_length = 120
13+
14+
[*.go]
15+
indent_style = tab
16+
indent_size = 4
17+
18+
[*.{yml,yaml}]
19+
indent_style = space
20+
indent_size = 2
21+
22+
[*.{sh,bash}]
23+
indent_style = space
24+
indent_size = 2
25+
26+
[*.{toml,cfg,ini}]
27+
indent_style = space
28+
indent_size = 4
29+
30+
[*.{js,ts,json}]
31+
indent_style = space
32+
indent_size = 2
33+
34+
[*.{html,css}]
35+
indent_style = space
36+
indent_size = 2
37+
38+
[*.md]
39+
trim_trailing_whitespace = false
40+
41+
[Dockerfile*]
42+
indent_style = space
43+
indent_size = 4
44+
45+
[*.Dockerfile]
46+
indent_style = space
47+
indent_size = 4
48+
49+
[Makefile]
50+
indent_style = tab
51+
52+
[justfile]
53+
indent_style = space
54+
indent_size = 4
55+
56+
[*.{tf,hcl}]
57+
indent_style = space
58+
indent_size = 2
59+
60+
[helm-deployments/**/*.yaml]
61+
indent_style = space
62+
indent_size = 2

docker/c-cpp.Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
# syntax=docker/dockerfile:1
22
# C/C++ execution environment with Docker Hardened Images.
3+
# Uses -dev variant because compilers and dev libraries must be available at runtime.
34

4-
FROM dhi.io/debian-base:trixie
5+
FROM dhi.io/debian-base:trixie-debian13-dev
56

67
ARG BUILD_DATE
78
ARG VERSION

docker/d.Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
# syntax=docker/dockerfile:1
22
# D execution environment with Docker Hardened Images.
3+
# Uses -dev variant because compilers must be available at runtime.
34

4-
FROM dhi.io/debian-base:trixie
5+
FROM dhi.io/debian-base:trixie-debian13-dev
56

67
ARG BUILD_DATE
78
ARG VERSION

docker/fortran.Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
# syntax=docker/dockerfile:1
22
# Fortran execution environment with Docker Hardened Images.
3+
# Uses -dev variant because compilers and dev libraries must be available at runtime.
34

4-
FROM dhi.io/debian-base:trixie
5+
FROM dhi.io/debian-base:trixie-debian13-dev
56

67
ARG BUILD_DATE
78
ARG VERSION

docker/go.Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
################################
55
# Stage 1: Build and download dependencies
6-
FROM dhi.io/golang:1.25-debian13-dev AS builder
6+
FROM dhi.io/golang:1.26-debian13-dev AS builder
77

88
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
99

@@ -26,7 +26,7 @@ RUN cd /tmp/gosetup && \
2626

2727
################################
2828
# Stage 2: Prepare runtime directories
29-
FROM dhi.io/golang:1.25-debian13-dev AS runtime-deps
29+
FROM dhi.io/golang:1.26-debian13-dev AS runtime-deps
3030

3131
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
3232

@@ -35,7 +35,7 @@ RUN mkdir -p /mnt/data /mnt/data/go-build && chown -R 65532:65532 /mnt/data
3535

3636
################################
3737
# Stage 3: Minimal runtime image
38-
FROM dhi.io/golang:1.25-debian13 AS final
38+
FROM dhi.io/golang:1.26-debian13 AS final
3939

4040
ARG BUILD_DATE
4141
ARG VERSION

docker/php.Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
# PHP execution environment with Docker Hardened Images.
33

44
# PHP version configuration - single source of truth
5-
ARG PHP_VERSION=8.4.17
6-
ARG PHP_MAJOR=8.4
5+
ARG PHP_VERSION=8.5.3
6+
ARG PHP_MAJOR=8.5
77
ARG DEBIAN_VERSION=debian13
88

99
ARG BUILD_DATE

docker/python.Dockerfile

Lines changed: 20 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,10 @@ ENV PIP_NO_BUILD_ISOLATION=1 \
5151
# Install pip and build tooling with compatible versions
5252
RUN --mount=type=cache,target=/root/.cache/pip \
5353
python -m pip install \
54-
"pip<24.1" \
55-
"setuptools<70" \
54+
"pip>=24.1" \
55+
"setuptools>=70" \
5656
wheel \
57-
"packaging<24"
57+
"packaging>=24"
5858

5959
# Copy requirements files
6060
COPY requirements/python-core.txt /tmp/python-core.txt
@@ -83,33 +83,34 @@ SHELL ["/bin/bash", "-o", "pipefail", "-c"]
8383
RUN mkdir -p /usr/lib/x86_64-linux-gnu /usr/lib/aarch64-linux-gnu && \
8484
apt-get update && \
8585
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
86-
# Runtime libraries (counterparts to -dev packages in builder)
87-
libxml2 \
88-
libxslt1.1 \
89-
libffi8 \
90-
libssl3t64 \
86+
# Core System Utilities
87+
libgomp1 \
88+
liblz4-1 \
89+
# Image Processing (Pillow, OpenCV)
90+
ffmpeg \
9191
libjpeg62-turbo \
9292
libpng16-16t64 \
9393
libtiff6 \
94+
libwebp7 \
9495
libopenjp2-7 \
95-
libfreetype6 \
9696
liblcms2-2 \
97-
libwebp7 \
98-
libportaudio2 \
99-
libpulse0 \
100-
# External tools needed at runtime
97+
# XML/HTML Processing (lxml, beautifulsoup4)
98+
libxml2 \
99+
libxslt1.1 \
100+
# Cryptography (cryptography, PyOpenSSL)
101+
libffi8 \
102+
libssl3t64 \
103+
# Font Support (Matplotlib, WordCloud)
104+
libfreetype6 \
105+
fontconfig \
106+
# External Tools (Runtime executables)
101107
poppler-utils \
102-
tesseract-ocr \
103-
pandoc \
104-
ffmpeg \
105-
flac \
106-
antiword \
107-
unrtf \
108108
&& apt-get autoremove -y \
109109
&& apt-get clean \
110110
&& rm -rf /var/lib/apt/lists/* \
111111
&& mkdir -p /mnt/data && chown 65532:65532 /mnt/data
112112

113+
113114
################################
114115
# Final stage - minimal runtime image
115116
################################
@@ -129,13 +130,7 @@ LABEL org.opencontainers.image.title="KubeCodeRun Python Environment" \
129130
COPY --from=runtime-deps /usr/lib/x86_64-linux-gnu /usr/lib/x86_64-linux-gnu
130131
COPY --from=runtime-deps /usr/lib/aarch64-linux-gnu /usr/lib/aarch64-linux-gnu
131132
COPY --from=runtime-deps /usr/bin/pdftotext /usr/bin/pdftoppm /usr/bin/pdfinfo /usr/bin/
132-
COPY --from=runtime-deps /usr/bin/tesseract /usr/bin/
133-
COPY --from=runtime-deps /usr/bin/pandoc /usr/bin/
134133
COPY --from=runtime-deps /usr/bin/ffmpeg /usr/bin/ffprobe /usr/bin/
135-
COPY --from=runtime-deps /usr/bin/flac /usr/bin/
136-
COPY --from=runtime-deps /usr/bin/antiword /usr/bin/
137-
COPY --from=runtime-deps /usr/bin/unrtf /usr/bin/
138-
COPY --from=runtime-deps /usr/share/tesseract-ocr /usr/share/tesseract-ocr
139134

140135
# Copy installed Python packages from builder
141136
# DHI Python is installed in /opt/python, not /usr/local

docker/r.Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ ARG VCS_REF
99
################################
1010
# Builder stage - install R and compile packages
1111
################################
12-
FROM dhi.io/debian-base:trixie AS builder
12+
FROM dhi.io/debian-base:trixie-debian13-dev AS builder
1313

1414
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
1515

@@ -40,7 +40,7 @@ RUN R -e "options(repos = c(CRAN = 'https://packagemanager.posit.co/cran/__linux
4040
################################
4141
# Final stage - runtime image
4242
################################
43-
FROM dhi.io/debian-base:trixie AS final
43+
FROM dhi.io/debian-base:trixie-debian13-dev AS final
4444

4545
ARG BUILD_DATE
4646
ARG VERSION

docker/requirements/go.mod

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
module preload
22

3-
go 1.25
3+
go 1.26
44

55
require (
6-
github.com/gorilla/mux v1.8.1
6+
github.com/davidbyttow/govips/v2 v2.16.0
7+
github.com/fatih/color v1.18.0
78
github.com/gin-gonic/gin v1.11.0
8-
github.com/sirupsen/logrus v1.9.4
9+
github.com/gocarina/gocsv v0.0.0-20240520201108-78e41c74b4b1
910
github.com/google/uuid v1.6.0
10-
github.com/shopspring/decimal v1.4.0
11-
gonum.org/v1/gonum v0.17.0
11+
github.com/gorilla/mux v1.8.1
1212
github.com/montanaflynn/stats v0.7.1
13-
github.com/xuri/excelize/v2 v2.10.0
13+
github.com/shopspring/decimal v1.4.0
14+
github.com/sirupsen/logrus v1.9.4
1415
github.com/spf13/cobra v1.10.2
15-
github.com/fatih/color v1.18.0
16-
github.com/gocarina/gocsv v0.0.0-20240520201108-78e41c74b4b1
1716
github.com/tidwall/gjson v1.18.0
17+
github.com/unidoc/unioffice/v2 v2.8.0
18+
github.com/xuri/excelize/v2 v2.10.0
19+
github.com/yuin/goldmark v1.7.16
20+
gonum.org/v1/gonum v0.17.0
21+
gopkg.in/yaml.v3 v3.0.1
1822
)

docker/requirements/nodejs.txt

Lines changed: 45 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,58 @@
1-
# Node.js global packages
2-
# One package per line for npm install -g
1+
# Node.js packages
2+
# One package per line: npm install -g <package>
33

4-
lodash
4+
# Core utilities
5+
archiver
56
axios
6-
moment
7-
uuid
87
chalk
98
commander
10-
express
11-
fs-extra
12-
csv-parser
13-
json2csv
14-
papaparse
15-
archiver
16-
yauzl
17-
pdf-lib
9+
crypto-js
1810
date-fns
11+
fs-extra
12+
lodash
13+
luxon
14+
uuid
1915
validator
20-
crypto-js
16+
zod
17+
18+
# Web scraping & parsing
19+
cheerio
20+
21+
# Data processing
22+
papaparse
2123
mathjs
2224
ml-matrix
2325
simple-statistics
24-
sharp
26+
27+
# File formats - Office documents
28+
exceljs
29+
xlsx
30+
pptxgenjs
31+
mammoth
32+
33+
# File formats - Other
34+
js-yaml
35+
marked
36+
pdf-lib
37+
38+
# Images
2539
jimp
40+
sharp
41+
42+
# Compression
43+
yauzl
44+
45+
# TypeScript (recommended local + global)
2646
typescript
2747
ts-node
28-
xlsx
29-
exceljs
30-
luxon
31-
zod
48+
@types/node
49+
50+
# Web frameworks
51+
express
3252
handlebars
33-
cheerio
34-
marked
53+
54+
# UI libraries
55+
jquery
56+
jquery-ui-dist
57+
three
58+
p5

0 commit comments

Comments
 (0)