Skip to content

Commit 7b3df61

Browse files
committed
🧱 QD-13151 Switch to DHI images
1 parent c746ec4 commit 7b3df61

19 files changed

+316
-135
lines changed

.devcontainer/Dockerfile

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,18 +15,17 @@
1515
#
1616
# This Dockerfile is for https://github.com/jetbrains/qodana-cli dev container.
1717

18-
FROM golang:bookworm
18+
FROM dhi.io/golang:1.25-debian13-dev
1919
ARG TARGETARCH
2020
ARG CLANG=16
2121
ENV TARGETARCH=$TARGETARCH \
2222
CLANG=$CLANG
2323
ENV CHOCO_VERSION=2.2.2 \
2424
GH_VERSION=2.41.0
25-
ENV MONO_REPO="https://download.mono-project.com/repo/debian" \
26-
MONO_KEY="3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF"
25+
ENV MONO_REPO="https://download.mono-project.com/repo/debian"
2726

28-
RUN set -ex && \
29-
apt-get update && apt-get install -y --no-install-recommends \
27+
RUN set -ex && ln -s /usr/bin/which.debianutils /usr/bin/which && \
28+
apt-get update && apt-get install -y --no-install-recommends init-system-helpers gzip wget \
3029
apt-transport-https \
3130
autoconf \
3231
automake \
@@ -40,16 +39,16 @@ RUN set -ex && \
4039
make \
4140
patch \
4241
libc6-dev \
42+
libicu76 \
4343
git \
4444
git-lfs \
4545
default-jre \
4646
xdg-utils
4747

4848
# note: choco is required for the full goreleaser functionality
4949
RUN set -ex && \
50-
mkdir -p /tmp /opt/chocolatey && \
51-
gpg --homedir /tmp --no-default-keyring --keyring /usr/share/keyrings/mono-official-archive-keyring.gpg \
52-
--keyserver hkp://keyserver.ubuntu.com:80 --recv-keys $MONO_KEY && \
50+
mkdir -p /tmp /opt/chocolatey /usr/local/bin && \
51+
curl -fsSL https://download.mono-project.com/repo/xamarin.gpg | gpg --dearmor > /usr/share/keyrings/mono-official-archive-keyring.gpg && \
5352
echo "deb [trusted=yes] https://repo.goreleaser.com/apt/ /" | tee /etc/apt/sources.list.d/goreleaser.list && \
5453
echo "deb [signed-by=/usr/share/keyrings/mono-official-archive-keyring.gpg] $MONO_REPO stable-buster main" | \
5554
tee /etc/apt/sources.list.d/mono-official-stable.list && \

.github/workflows/base.yml

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,19 @@ jobs:
2020
strategy:
2121
fail-fast: false
2222
matrix:
23-
group: ["default", "more", "clang", "ruby"]
23+
group:
24+
- jvm # jvm-community → jvm → python-community → python
25+
- dotnet # dotnet-community → dotnet
26+
- clang # clang 20, 21 (Trixie)
27+
- clang-16 # clang 16 (Bookworm)
28+
- clang-17 # clang 17 (Bookworm)
29+
- clang-18 # clang 18 (Bookworm)
30+
- clang-19 # clang 19 (Bookworm)
31+
- go # standalone
32+
- js # standalone
33+
- php # standalone
34+
- rust # standalone
35+
- ruby # ruby 3.2, 3.3, 3.4
2436
runs-on: ubuntu-latest
2537
steps:
2638
- name: Clean up
@@ -40,6 +52,11 @@ jobs:
4052
registry: registry.jetbrains.team
4153
username: ${{ secrets.SPACE_USERNAME }}
4254
password: ${{ secrets.SPACE_PASSWORD }}
55+
- uses: docker/login-action@v3
56+
with:
57+
registry: dhi.io
58+
username: ${{ secrets.DHI_USERNAME }}
59+
password: ${{ secrets.DHI_PASSWORD }}
4360
- name: Build and push
4461
uses: docker/bake-action@v6
4562
with:

.github/workflows/devcontainer.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,11 @@ jobs:
3434
registry: ghcr.io
3535
username: ${{ github.actor }}
3636
password: ${{ secrets.GITHUB_TOKEN }}
37+
- uses: docker/login-action@v3
38+
with:
39+
registry: dhi.io
40+
username: ${{ secrets.DHI_USERNAME }}
41+
password: ${{ secrets.DHI_PASSWORD }}
3742
- uses: docker/setup-qemu-action@v3
3843
- uses: docker/setup-buildx-action@v3
3944
- uses: docker/build-push-action@v6

.github/workflows/docker-ci.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,11 @@ jobs:
4747
uses: actions/checkout@v6
4848
- name: Set up Docker Buildx
4949
uses: docker/setup-buildx-action@v3
50+
- uses: docker/login-action@v3
51+
with:
52+
registry: dhi.io
53+
username: ${{ secrets.DHI_USERNAME }}
54+
password: ${{ secrets.DHI_PASSWORD }}
5055
- name: Build
5156
uses: docker/build-push-action@v6
5257
with:
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
FROM debian:bookworm-slim
2+
ARG CLANG="18"
3+
4+
ENV HOME="/root" \
5+
LC_ALL="en_US.UTF-8" \
6+
QODANA_DIST="/opt/idea" \
7+
QODANA_DATA="/data" \
8+
QODANA_DOCKER="true"
9+
10+
ENV JAVA_HOME="$QODANA_DIST/jbr" \
11+
QODANA_CONF="$HOME/.config/idea" \
12+
PATH="/opt/qodana:$QODANA_DIST/bin:${PATH}"
13+
14+
ENV CXX="/usr/lib/llvm-$CLANG/bin/clang++" \
15+
CC="/usr/lib/llvm-$CLANG/bin/clang" \
16+
CPLUS_INCLUDE_PATH="/usr/lib/clang/$CLANG/include"
17+
18+
# hadolint ignore=SC2174,DL3009
19+
RUN --mount=target=/var/lib/apt/lists,type=cache,sharing=locked \
20+
--mount=target=/var/cache/apt,type=cache,sharing=locked \
21+
rm -f /etc/apt/apt.conf.d/docker-clean && \
22+
mkdir -m 777 -p /opt/qodana $QODANA_DATA/project $QODANA_DATA/cache $QODANA_DATA/results && apt-get update && \
23+
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
24+
ca-certificates \
25+
curl \
26+
default-jre \
27+
gawk \
28+
git \
29+
git-lfs \
30+
gnupg2 \
31+
apt-transport-https \
32+
autoconf \
33+
automake \
34+
cmake \
35+
dpkg-dev \
36+
file \
37+
make \
38+
patch \
39+
libc6-dev \
40+
locales && \
41+
echo 'en_US.UTF-8 UTF-8' > /etc/locale.gen && locale-gen && \
42+
apt-get autoremove -y && apt-get clean && \
43+
chmod 777 -R $HOME && \
44+
echo 'root:x:0:0:root:/root:/bin/bash' > /etc/passwd && chmod 666 /etc/passwd && \
45+
git config --global --add safe.directory '*'
46+
47+
RUN echo "deb https://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-${CLANG} main" > /etc/apt/sources.list.d/llvm.list && \
48+
curl -s https://apt.llvm.org/llvm-snapshot.gpg.key | gpg --dearmor > /etc/apt/trusted.gpg.d/llvm.gpg && \
49+
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys "15CF4D18AF4F7421" && \
50+
apt-get -qq update && \
51+
apt-get install -qqy -t \
52+
llvm-toolchain-bookworm-$CLANG \
53+
clang-$CLANG \
54+
clang-tidy-$CLANG \
55+
clang-format-$CLANG \
56+
lld-$CLANG \
57+
libc++-$CLANG-dev \
58+
libc++abi-$CLANG-dev && \
59+
for f in /usr/lib/llvm-$CLANG/bin/*; do ln -sf "$f" /usr/bin; done && \
60+
ln -sf clang /usr/bin/cc && \
61+
ln -sf clang /usr/bin/c89 && \
62+
ln -sf clang /usr/bin/c99 && \
63+
ln -sf clang++ /usr/bin/c++ && \
64+
ln -sf clang++ /usr/bin/g++ && \
65+
rm -rf /var/lib/apt/lists/* && \
66+
apt-get autoremove -y && apt-get clean
67+

dockerfiles/base/cpp-community.Dockerfile

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
ARG BASE_TAG="bookworm-slim"
2-
FROM debian:$BASE_TAG
3-
ARG CLANG="16"
1+
ARG BASE_TAG="trixie"
2+
FROM dhi.io/debian-base:$BASE_TAG
3+
ARG CLANG="20"
44

55
ENV HOME="/root" \
66
LC_ALL="en_US.UTF-8" \
@@ -25,6 +25,7 @@ RUN --mount=target=/var/lib/apt/lists,type=cache,sharing=locked \
2525
ca-certificates \
2626
curl \
2727
default-jre \
28+
gawk \
2829
git \
2930
git-lfs \
3031
gnupg2 \
@@ -44,12 +45,11 @@ RUN --mount=target=/var/lib/apt/lists,type=cache,sharing=locked \
4445
echo 'root:x:0:0:root:/root:/bin/bash' > /etc/passwd && chmod 666 /etc/passwd && \
4546
git config --global --add safe.directory '*'
4647

47-
RUN echo "deb https://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-${CLANG} main" > /etc/apt/sources.list.d/llvm.list && \
48+
RUN echo "deb https://apt.llvm.org/trixie/ llvm-toolchain-trixie-${CLANG} main" > /etc/apt/sources.list.d/llvm.list && \
4849
curl -s https://apt.llvm.org/llvm-snapshot.gpg.key | gpg --dearmor > /etc/apt/trusted.gpg.d/llvm.gpg && \
49-
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys "15CF4D18AF4F7421" && \
5050
apt-get -qq update && \
5151
apt-get install -qqy -t \
52-
llvm-toolchain-bookworm-$CLANG \
52+
llvm-toolchain-trixie-$CLANG \
5353
clang-$CLANG \
5454
clang-tidy-$CLANG \
5555
clang-format-$CLANG \

dockerfiles/base/cpp.Dockerfile

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
1-
ARG BASE_TAG="bookworm-slim"
2-
ARG NODE_TAG="22-bookworm-slim"
3-
FROM node:$NODE_TAG AS node_base
1+
ARG BASE_TAG="trixie"
2+
ARG NODE_TAG="22-debian13-dev"
3+
FROM dhi.io/node:$NODE_TAG AS node_base
44
FROM cpp-community
55

66
# renovate: datasource=npm depName=eslint
77
ENV ESLINT_VERSION="9.31.0"
8-
# renovate: datasource=npm depName=pnpm
9-
ENV PNPM_VERSION="10.13.1"
108

119
ENV PATH="/opt/yarn/bin:$PATH"
1210
ENV SKIP_YARN_COREPACK_CHECK=0
13-
COPY --from=node_base /usr/local/bin/node /usr/local/bin/
14-
COPY --from=node_base /usr/local/include/node /usr/local/include/node
15-
COPY --from=node_base /usr/local/lib/node_modules /usr/local/lib/node_modules
16-
COPY --from=node_base /opt/yarn-* /opt/yarn/
11+
COPY --from=node_base /opt/nodejs/node-*/bin/node /usr/local/bin/
12+
COPY --from=node_base /opt/nodejs/node-*/include/node /usr/local/include/node
13+
COPY --from=node_base /opt/nodejs/node-*/lib/node_modules /usr/local/lib/node_modules
14+
COPY --from=node_base /opt/yarn/ /opt/yarn/
1715
RUN ln -s /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm && \
1816
ln -s /usr/local/lib/node_modules/npm/bin/npx-cli.js /usr/local/bin/npx && \
1917
ln -s /usr/local/lib/node_modules/corepack/dist/corepack.js /usr/local/bin/corepack && \
18+
mkdir -p /opt/yarn/bin && ln -s /opt/yarn/yarn-*/bin/yarn /opt/yarn/bin/ && \
19+
ln -s /opt/yarn/yarn-*/bin/yarnpkg /opt/yarn/bin/ && \
2020
node --version && \
2121
npm --version && \
2222
yarn --version && \
23-
npm install -g eslint@$ESLINT_VERSION pnpm@$PNPM_VERSION && npm config set update-notifier false && \
23+
npm install -g eslint@$ESLINT_VERSION && npm config set update-notifier false && \
2424
chmod 777 -R "$HOME/.npm" "$HOME/.npmrc" && \
2525
apt-get update && \
2626
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \

0 commit comments

Comments
 (0)