# Stage 1: builder
FROM rust:1.70-slim AS builder
WORKDIR /app
# Install dependencies required for building the project (GTK 4, Adwaita, protobuf, etc.)
RUN apt-get update && \
apt-get install -y --no-install-recommends \
build-essential \
pkg-config \
libgtk-4-dev \
libadwaita-1-dev \
protobuf-compiler \
ca-certificates \
curl \
git \
&& rm -rf /var/lib/apt/lists/*
# Copy the repository and build
COPY . .
RUN cargo build --release
# Stage 2: runtime
FROM debian:bookworm-slim
ENV DEBIAN_FRONTEND=noninteractive
# Install runtime dependencies for GTK application
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-4 \
libadwaita-1-0 \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
__pycache__ *.pyc *.pyo *.o node_modules/ .git/ target/ **/*.rlib *.sqlite *.db Cargo.lock
- Exact error message and exit code - ERROR: process "/bin/sh -c apt-get update && apt-get install -y --no-install-recommends ca-certificates libgtk-4-4 libadwaita-1-0 && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100 - Failing command/step - [stage-1 2/4] RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates libgtk-4-4 libadwaita-1-0 && rm -rf /var/lib/apt/lists/* - Missing packages or files mentioned - E: Unable to locate package libgtk-4-4 - Version/distro context (any relevant mismatch) - Base image context shown: using Debian bookworm-slim in stage-1 (and rust:1.70-slim as builder). The failure indicates libgtk-4-4 is not available in the apt repositories for this Debian version, suggesting a package availability issue rather than a transient download error. No explicit version mismatch is reported beyond the missing package in this distro/version.
No results found.
# Stage 1: builder
FROM rust:1.70-slim AS builder
WORKDIR /app
# Install dependencies required for building the project (GTK 4, Adwaita, protobuf, etc.)
RUN apt-get update && \
apt-get install -y --no-install-recommends \
build-essential \
pkg-config \
libgtk-4-dev \
libadwaita-1-dev \
protobuf-compiler \
ca-certificates \
curl \
git \
&& rm -rf /var/lib/apt/lists/*
# Copy the repository and build
COPY . .
RUN cargo build --release
# Stage 2: runtime
FROM debian:bookworm-slim
ENV DEBIAN_FRONTEND=noninteractive
# Install runtime dependencies for GTK application
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-1 \
libadwaita-1 \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
Summary (under 1500 chars): - Exact error message and exit code - ERROR: process "/bin/sh -c apt-get update && apt-get install -y --no-install-recommends ca-certificates libgtk-4-1 libadwaita-1 && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100 - E: Unable to locate package libadwaita-1 - Failing command/step - Dockerfile: stage-1, RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates libgtk-4-1 libadwaita-1 && rm -rf /var/lib/apt/lists/* - Specifically the apt-get install line including libadwaita-1 - Missing packages or files mentioned - libadwaita-1 is not found in the configured apt repositories for the base image - Version mismatch info - Base images involved: rust:1.70-slim and Debian bookworm-slim - The failure indicates libadwaita-1 is unavailable in the Debian bookworm-slim repositories being used, rather than a misconfigured version number in the Dockerfile.
# Stage 1: builder (Ubuntu 22.04 with Rust installed via rustup)
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
# Install build dependencies and GTK4 development headers
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
build-essential \
pkg-config \
curl \
git \
libgtk-4-dev \
libadwaita-1-dev \
protobuf-compiler \
zlib1g-dev \
libgl1 \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
ENV PATH=/root/.cargo/bin:${PATH}
# Copy the repository and build
WORKDIR /app
COPY . .
RUN cargo build --release
# Stage 2: runtime image
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
# Runtime GTK dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-1 \
libadwaita-1 \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder stage
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
Summary of Docker build error
- Failing step
- Stage: stage-1, step 2/4
- Command:
RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates libgtk-4-1 libadwaita-1 && rm -rf /var/lib/apt/lists/*
- Dockerfile reference: Dockerfile:36
- Exact error message and exit code
- Error text:
ERROR: failed to build: failed to solve: process "/bin/sh -c apt-get update && apt-get install -y --no-install-recommends ca-certificates libgtk-4-1 libadwaita-1 && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100
- apt error during this step:
E: Unable to locate package libadwaita-1
- Missing packages or files mentioned
- libadwaita-1 (not found)
- Version mismatch / package naming hints
- Later logs show package names such as libadwaita-1-0 and libadwaita-1-dev being installed in a subsequent/alternate apt invocation, indicating a package naming/version mismatch for libadwaita on this base image or repository.
Example: The log lists “The following NEW packages will be installed: … libadwaita-1-0 … libadwaita-1-dev …”# Stage 1: builder
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
# Install build dependencies and GTK4 development headers
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
build-essential \
pkg-config \
curl \
git \
libgtk-4-dev \
libadwaita-1-dev \
protobuf-compiler \
zlib1g-dev \
libgl1-mesa-dev \
libx11-dev \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
ENV PATH=/root/.cargo/bin:${PATH}
# Copy the repository and build
WORKDIR /app
COPY . .
RUN cargo build --release
# Stage 2: runtime image
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
# Runtime GTK dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-1 \
libadwaita-1 \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder stage
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
- Exact error message and exit code - E: Unable to locate package libadwaita-1 - exit code: 100 - Failing command/step - Stage-1 [2/4]: RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates libgtk-4-1 libadwaita-1 && rm -rf /var/lib/apt/lists/* - Missing packages or files mentioned - libadwaita-1 - Version mismatch / repo context - The build pulls from Ubuntu 22.04 (jammy) repositories. The first stage cannot locate libadwaita-1, while a later stage shows libadwaita-related packages (e.g., libadwaita-1-dev, libadwaita-1-0) being installed, indicating a discrepancy in package availability/name between stages or between apt sources used at different times. No explicit version mismatch is shown, but package availability for libadwaita-1 differs between stages.
# Stage 1: builder
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
# Install build dependencies and GTK4 development headers
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
build-essential \
pkg-config \
curl \
git \
libgtk-4-dev \
libadwaita-1-0 \
libadwaita-1-dev \
protobuf-compiler \
zlib1g-dev \
libgl1-mesa-dev \
libx11-dev \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
ENV PATH=/root/.cargo/bin:${PATH}
# Copy the repository and build
WORKDIR /app
COPY . .
RUN cargo build --release
# Stage 2: runtime image
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
# Runtime GTK dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-1 \
libadwaita-1-0 \
fontconfig \
shared-mime-info \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder stage
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
- Exact error message and exit code
- error: failed to run custom build command for `gdk4-sys v0.9.6`
- Caused by:
- process didn't exit successfully: `/app/target/release/build/gdk4-sys-f60bf0e9ececb9de/build-script-build` (exit status: 1)
- stdout highlights:
- pkg-config exited with status code 1
- > PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1 pkg-config --libs --cflags gtk4 'gtk4 >= 4.16'
- The system library `gtk4` required by crate `gdk4-sys` was not found.
- The file `gtk4.pc` needs to be installed and the PKG_CONFIG_PATH environment variable must contain its parent directory.
- The PKG_CONFIG_PATH environment variable is not set.
- HINT: if you have installed the library, try setting PKG_CONFIG_PATH to the directory containing `gtk4.pc`.
- Exit code: 101
- Failing command/step
- Step: RUN cargo build --release (builder 6/6)
- Missing packages or files mentioned
- gtk4.pc missing (The system library gtk4 was not found; gtk4.pc not found in PKG_CONFIG_PATH)
- PKG_CONFIG_PATH environment variable is not set
- Version mismatch / environment details
- Base image uses Ubuntu 22.04 (jammy) with GTK4-related packages installed (e.g., libgtk-4-dev, gtk4-sys crate v0.9.6).
- Rust toolchain shown in log: rustup install flow yields stable-x86_64-unknown-linux-gnu, rustc 1.94.0 (2026-03-02).
- GTK4 PKG_CONFIG_PATH not set despite GTK4 development files installed, causing gdk4-sys build to fail.# Stage 1: builder
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
# Install build dependencies and GTK4 development headers
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
build-essential \
pkg-config \
curl \
git \
libgtk-4-dev \
libadwaita-1-dev \
protobuf-compiler \
zlib1g-dev \
libgl1-mesa-dev \
libx11-dev \
&& rm -rf /var/lib/apt/lists/*
# PKG_CONFIG_PATH helps gtk4-sys find gtk4
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig
# Install Rust toolchain
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
ENV PATH=/root/.cargo/bin:${PATH}
# Copy the repository and build
WORKDIR /app
COPY . .
RUN cargo build --release
# Stage 2: runtime image
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
# Runtime GTK dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-1 \
libadwaita-1-0 \
fontconfig \
shared-mime-info \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder stage
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
Concise summary of the Docker build error
- Exact error message and exit code
- error: failed to run custom build command for `gdk4-sys v0.9.6`
- Caused by: process didn't exit successfully: `/app/target/release/build/gdk4-sys-f60bf0e9ececb9de/build-script-build` (exit status: 1)
- The system library `gtk4` required by crate `gdk4-sys` was not found.
- The file `gtk4.pc` needs to be installed and the PKG_CONFIG_PATH environment variable must contain its parent directory.
- PKG_CONFIG_PATH contains the following:
- /usr/lib/x86_64-linux-gnu/pkgconfig
- /usr/lib/pkgconfig
- /usr/share/pkgconfig
- HINT: you may need to install a package such as gtk4, gtk4-dev or gtk4-devel.
- Failing command/step
- RUN cargo build --release
- Dockerfile:32 (builder 6/6)
- Missing packages or files mentioned
- gtk4 (GTK4)
- gtk4-dev or gtk4-devel
- gtk4.pc (PKG_CONFIG_PATH needs to include its location)
- Version mismatch / runtime tooling notes
- info: latest update on 2026-03-05 for version 1.94.0 (4a4ef493e 2026-03-02)
- The run shows Rust toolchain being installed via rustup (stable-x86_64-unknown-linux-gnu) and then building the project; PKG-config failure is GTK4-related, not Rust version-related, but this Rust version detail is present in the log.# Stage 1: builder
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
# Install build dependencies and GTK4 development headers
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
build-essential \
pkg-config \
curl \
git \
gtk4 \
libgtk-4-dev \
libadwaita-1-dev \
protobuf-compiler \
fonts-noto-color-emoji \
libwayland-client0 \
libwayland-cursor0 \
libwayland-egl1 \
libxkbcommon0 \
&& rm -rf /var/lib/apt/lists/*
# PKG_CONFIG_PATH helps gtk4-sys find gtk4
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig
# Install Rust toolchain
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
ENV PATH=/root/.cargo/bin:${PATH}
# Copy the repository and build
WORKDIR /app
COPY . .
RUN cargo build --release
# Stage 2: runtime image
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
# Runtime GTK dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-1 \
libadwaita-1-0 \
fontconfig \
shared-mime-info \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder stage
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
- Failing step: [builder 2/6] RUN apt-get update && apt-get install -y --no-install-recommends \
ca-certificates, build-essential, pkg-config, curl, git, gtk4, libgtk-4-dev, libadwaita-1-dev, protobuf-compiler, fonts-noto-color-emoji, libwayland-client0, libwayland-cursor0, libwayland-egl1, libxkbcommon0 && rm -rf /var/lib/apt/lists/*
- Exact error message and exit code: E: Unable to locate package gtk4 and the process did not complete successfully: exit code: 100
- Missing packages/files: gtk4 is not found; libgtk-4-dev is present, but gtk4 package is unavailable.
- Version/environment context: Base image ubuntu:22.04 (Jammy). apt sources indicate Jammy, but gtk4 is not available in these repos.
- Dockerfile reference (explicit failing snippet):
Dockerfile:7
6 | # Install build dependencies and GTK4 development headers
7 | >>> RUN apt-get update && \
8 | >>> apt-get install -y --no-install-recommends \
9 | >>> ca-certificates \
10 | >>> build-essential \
11 | >>> pkg-config \
12 | >>> curl \
13 | >>> git \
14 | >>> gtk4 \
15 | >>> libgtk-4-dev \
16 | >>> libadwaita-1-dev \
17 | >>> protobuf-compiler \
18 | >>> fonts-noto-color-emoji \
19 | >>> libwayland-client0 \
20 | >>> libwayland-cursor0 \
21 | >>> libwayland-egl1 \
22 | >>> libxkbcommon0 \
23 | >>> && rm -rf /var/lib/apt/lists/*
- Actionable note: To resolve, ensure GTK4 package is available in the base image's apt sources (or remove gtk4 and rely on libgtk-4-dev for headers), or switch to a base image/repo where gtk4 is published.# Stage 1: builder
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
# Install build dependencies and GTK4 development headers
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
build-essential \
pkg-config \
curl \
git \
gtk4 \
libgtk-4-dev \
libadwaita-1-dev \
protobuf-compiler \
fonts-noto-color-emoji \
libwayland-client0 \
libwayland-cursor0 \
libwayland-egl1 \
libxkbcommon0 \
&& rm -rf /var/lib/apt/lists/*
# PKG_CONFIG_PATH helps gtk4-sys find gtk4
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig
# Install Rust toolchain
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
ENV PATH=/root/.cargo/bin:${PATH}
# Copy the repository and build
WORKDIR /app
COPY . .
RUN cargo build --release
# Stage 2: runtime image
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
# Runtime GTK dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-1 \
libadwaita-1-0 \
fontconfig \
shared-mime-info \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder stage
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
- Exact error message and exit code: - E: Unable to locate package gtk4 - exit code: 100 - Failing command/step: - [builder 2/6] RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates build-essential pkg-config curl git gtk4 libgtk-4-dev libadwaita-1-dev protobuf-compiler fonts-noto-color-emoji libwayland-client0 libwayland-cursor0 libwayland-egl1 libxkbcommon0 && rm -rf /var/lib/apt/lists/* - Dockerfile:7 - Missing packages or files mentioned: - gtk4 package not found (missing in jammy/Ubuntu 22.04 repositories for this build context) - Version mismatch information: - Base image: ubuntu:22.04 (jammy) - apt-get output shows jammy InRelease sources; the failure occurs during installation of gtk4 on a jammy system, suggesting gtk4 is not available in the current repositories for this image.
# Stage 1: builder
FROM debian:bookworm-slim AS builder
ENV DEBIAN_FRONTEND=noninteractive
# Install build dependencies and GTK4 development headers
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
build-essential \
pkg-config \
curl \
git \
libgtk-4-dev \
libadwaita-1-dev \
protobuf-compiler \
fonts-noto-color-emoji \
&& rm -rf /var/lib/apt/lists/*
# PKG_CONFIG_PATH helps gtk4-sys find gtk4
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig
# Install Rust toolchain
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
ENV PATH=/root/.cargo/bin:${PATH}
# Copy the repository and build
WORKDIR /app
COPY . .
RUN cargo build --release
# Stage 2: runtime image
FROM debian:bookworm-slim
ENV DEBIAN_FRONTEND=noninteractive
# Runtime GTK dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
libgtk-4-1 \
libadwaita-1-0 \
fontconfig \
shared-mime-info \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder stage
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
WORKDIR /app
CMD ["anime-game-launcher"]
Build summary: - VerifyBuild status: build_failed - Concerns: LLM review failed — building without review Failing step: - RUN cargo build --release (builder 6/6) Exact error (verbatim): - error: failed to run custom build command for `gdk4-sys v0.9.6` - Caused by: process didn't exit successfully: `/app/target/release/build/gdk4-sys-f60bf0e9ececb9de/build-script-build` (exit status: 1) - stdout mentions: cargo:rerun-if-changed=/root/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/gdk4-sys-0.9.6/Cargo.toml - The system library `gtk4` required by crate `gdk4-sys` was not found. - The file `gtk4.pc` needs to be installed and PKG_CONFIG_PATH must contain its parent directory. - PKG_CONFIG_PATH currently includes: /usr/lib/x86_64-linux-gnu/pkgconfig; /usr/lib/pkgconfig; /usr/share/pkgconfig - HINT: you may need to install a package such as gtk4, gtk4-dev or gtk4-devel. - Warning: build failed, waiting for other jobs to finish... - Dockerfile:30 - Exact exit code: 101 - Final: ERROR: failed to build: failed to solve: process "/bin/sh -c cargo build --release" did not complete successfully: exit code: 101 Missing packages/files: - gtk4.pc (GTK4 development pkg-config file) not found - Suggested fix in log: install gtk4, gtk4-dev or gtk4-devel - The crate gdk4-sys requires GTK4 (gtk4 >= 4.16) Version/context: - gdk4-sys v0.9.6 failed due to GTK4 not found; crate requires GTK4 >= 4.16 - Log implies system GTK4 dev headers are older or gtk4.pc missing - Earlier apt steps show installed GTK4-related packages (e.g., libgtk-4-dev, libgtk-4-1), but gtk4.pc is absent or too old for this crate Next actions (from log guidance): - Install GTK4 development package (gtk4, gtk4-dev or gtk4-devel) - Ensure gtk4.pc is available in PKG_CONFIG_PATH (path containing its parent dir) - Verify GTK4 version is >= 4.16 - Re-run: cargo build --release
# .dockerignore .git node_modules target .github .DS_Store *.log build dist
# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 as builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev ca-certificates \
&& rm -rf /var/lib/apt/lists/*
# Install Rust
RUN curl --proto '=https' --tls1.2 -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy manifest and fetch dependencies
COPY Cargo.toml Cargo.lock ./
RUN cargo fetch
# Copy the rest of the source
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 as runtime
ENV DEBIAN_FRONTEND=noninteractive
# Install runtime dependencies for GTK4 app
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 \
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary from builder
COPY --from=builder /app/target/release/* /usr/local/bin/
CMD ["anime-game-launcher"]
- VerifyBuild status: build_failed - Concerns - CMD assumes release binary named anime-game-launcher; actual binary may differ (Rust often builds with underscores, e.g., anime_game_launcher) - COPY --from=builder /app/target/release/* /usr/local/bin/ may copy multiple files; consider copying only the intended binary - No HEALTHCHECK defined; GUI apps in containers may require a display server or headless startup considerations - Build error - Exact error: E: Unable to locate package libadwaita-1 - Exit code: 100 - Context: runtime apt-get install failed with exit code 100 due to the missing package - Failing command/step - [runtime 2/5] RUN apt-get update && apt-get install -y --no-install-recommends libgtk-4-1 libadwaita-1 libglib2.0-0 libpango-1.0-0 libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 fonts-dejavu-core libcairo2 libfontconfig1 && rm -rf /var/lib/apt/lists/* - Missing packages or files mentioned - libadwaita-1 is reported missing: E: Unable to locate package libadwaita-1 - Build logs show the builder stage will install libadwaita-1-0, implying a version/name mismatch between stages - Version mismatch info - Builder stage package: libadwaita-1-0 (available) - Runtime install command requests libadwaita-1 (non-existent in the repo) - Indicates a package name/version mismatch: libadwaita-1 (expected) vs libadwaita-1-0 (available) - Implications / quick fix idea - Align the package name with Ubuntu 22.04 (jammy) availability, e.g., install libadwaita-1-0 (or the correct runtime package name) instead of libadwaita-1 - Ensure both builder and runtime stages use the same, valid package names for libadwaita - Note - Repeated casing warnings present in log but not included here per request
# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 as builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev ca-certificates \
&& rm -rf /var/lib/apt/lists/*
# Install Rust
RUN curl --proto '=https' --tls1.2 -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy manifest and fetch dependencies
COPY Cargo.toml Cargo.lock ./
RUN cargo fetch
# Copy the rest of the source
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 as runtime
ENV DEBIAN_FRONTEND=noninteractive
# Install runtime dependencies for GTK4 app
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 \
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary from builder
COPY --from=builder /app/target/release/* /usr/local/bin/
CMD ["anime-game-launcher"]
Exact error and exit code:
- cargo fetch exited with code 127
- Error text: "/bin/sh: 1: cargo: not found"
Failing command/step:
- [builder 6/8] RUN cargo fetch (Dockerfile sequence after copying Cargo.toml Cargo.lock)
Missing packages/files mentioned:
- cargo binary not found (Rust toolchain not installed)
- rustup installation likely halted earlier: the curl-based rustup installer failed
- Relevant message: "curl: option --tls1.2: is unknown" (builder 3/8)
Version mismatch / other notes:
- TLS flag issue observed in curl invocation suggests an incompatibility between the base image's curl and the rustup installer script ("--tls1.2" not supported)
- The logs also show a long apt-get install/update process with many package upgrades (e.g., gcc-12-base upgraded, libicu70, libc6-dev, etc.), indicating potential base-image version drift between stages.
- Warnings about casing in Dockerfile were present but not the root cause.# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev ca-certificates \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy manifest first to leverage build cache
COPY Cargo.toml Cargo.lock ./
RUN cargo fetch
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 \
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary from builder
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
CMD ["anime-game-launcher"]
Concerns: COPY instruction in the final stage runs after USER appuser, which will attempt to copy into /usr/local/bin as non-root; this will fail at build time due to permissions., If the build somehow succeeds, ensure the runtime image has all necessary GTK and related libraries for the anime-game-launcher; current list may or may not cover all runtime dependencies for the binary.
# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev ca-certificates \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy manifest first to leverage build cache
COPY Cargo.toml Cargo.lock ./
RUN cargo fetch
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from builder
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Ensure binary is executable by the non-root user
RUN chmod +x /usr/local/bin/anime-game-launcher
CMD ["anime-game-launcher"]
Summary:
- Failing step and command:
- [builder 6/8] RUN cargo fetch (Dockerfile:20)
- Exact error message and exit code:
- error: failed to parse manifest at `/app/Cargo.toml`
Caused by:
no targets specified in the manifest
either src/lib.rs, src/main.rs, a [lib] section, or [[bin]] section must be present
ERROR: process "/bin/sh -c cargo fetch" did not complete successfully: exit code: 101
- Failing Dockerfile context (snippet showing the failing line):
- Dockerfile:20
--------------------
18 | # Copy manifest first to leverage build cache
19 | COPY Cargo.toml Cargo.lock ./
20 | >>> RUN cargo fetch
21 |
22 | COPY . .
--------------------
- Missing packages/files indicated:
- Cargo.toml has no targets specified; there is no src/main.rs or src/lib.rs, and no [lib] or [[bin]] sections present to define a build target.
- Version/mismatch information:
- Rust toolchain installed: stable-x86_64-unknown-linux-gnu
- rustc 1.94.0 (4a4ef493e 2026-03-02)
- Latest update on 2026-03-05 for version 1.94.0 (4a4ef493e 2026-03-02)
- Likely cause:
- The manifest (/app/Cargo.toml) lacks a defined target (no lib/bin), causing cargo fetch to fail with exit code 101. Add a src/lib.rs or src/main.rs or declare [lib] / [[bin]] targets.# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev ca-certificates \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy the entire repository
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 \
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary from builder
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Ensure binary is executable
RUN chmod +x /usr/local/bin/anime-game-launcher
CMD ["anime-game-launcher"]
- Failing step/command
- [builder 6/6] RUN cargo build --release
- Exact error message and exit code
- error: failed to run custom build command for `gdk4-sys v0.9.6`
- Caused by:
- process didn't exit successfully: `/app/target/release/build/gdk4-sys-f60bf0e9ececb9de/build-script-build` (exit status: 1)
- The system library `gtk4` required by crate `gdk4-sys` was not found.
- The file `gtk4.pc` needs to be installed and the PKG_CONFIG_PATH environment variable must contain its parent directory.
- PKG_CONFIG_PATH contains the following:
- /usr/lib/x86_64-linux-gnu/pkgconfig
- /usr/lib/pkgconfig
- HINT: you may need to install a package such as gtk4, gtk4-dev or gtk4-devel.
- Missing packages/files mentioned
- gtk4.pc missing (system GTK4 development files not found)
- Suggested fixes mention installing gtk4, gtk4-dev (GTK4 environment not detected by the build)
- Version/mismatch information
- GTK4 related packages were installed in the build stages (e.g., libgtk-4-dev and other GTK4-related deps in runtime/build steps), with GTK4-related components such as libgtk-4-1 (4.6.9) and libgtk-4-dev present in the logs.
- Despite these, gtk4.pc was not found, causing the gdk4-sys build script to fail.
- GTK4-related hints indicate a mismatch between installed GTK4 components and what cargo/pkg-config expects (gtk4.pc not available in PKG_CONFIG_PATH).# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf2.0-dev \
libpango1.0-dev libcairo2-dev libfontconfig1-dev libwayland-client0-dev \
libwayland-egl1-dev libx11-dev \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy the entire repository
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 libgl1 \
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary from builder (cargo typically names the binary anime_game_launcher)
COPY --from=builder /app/target/release/anime_game_launcher /usr/local/bin/anime_game_launcher
# Ensure binary is executable
RUN chmod +x /usr/local/bin/anime_game_launcher
CMD ["anime_game_launcher"]
- Failing step (command): Dockerfile:6 RUN apt-get update && apt-get install -y --no-install-recommends build-essential pkg-config git curl protobuf-compiler libprotobuf-dev libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf2.0-dev libpango1.0-dev libcairo2-dev libfontconfig1-dev libwayland-client0-dev libwayland-egl1-dev libx11-dev && rm -rf /var/lib/apt/lists/* - Exact error messages and exit code: E: Unable to locate package libwayland-client0-dev E: Unable to locate package libwayland-egl1-dev exit code: 100 The overall failure shows: ERROR: failed to build: failed to solve: process "/bin/sh -c apt-get update ... && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100 - Missing packages mentioned: - libwayland-client0-dev - libwayland-egl1-dev - Version/mismatch information: - Base image targets Ubuntu 22.04 (Jammy). Repos shown include jammy/InRelease, jammy-security, jammy-updates, jammy-backports. The missing dev packages suggest these specific package names are not available in Jammy's repositories (possible naming changes or required components not enabled), indicating a package-name/version mismatch with the distro in use.
- Localization setup
- Uses fluent_templates and unic_langid.
- LOCALES static loader:
- locales: "./assets/locales"
- core_locales: "./assets/locales/common.ftl"
- fallback_language: "en"
- Supported languages
- SUPPORTED_LANGUAGES: 20 entries
- en-us, ru-ru, de-de, fr-fr, es-es, tr-tr, it-it, id-id, zh-cn, ja-jp, ko-kr, hu-hu, sv-se, pt-br, pl-pl, vi-vn, nl-nl, uk-ua, th-th, cs-cz
- Fallback and language storage
- FALLBACK: en-us
- LANG: OnceLock<LanguageIdentifier>
- Functions
- set_lang(lang: LanguageIdentifier) -> Result
- If lang.language matches any supported entry’s language component, sets LANG and returns Ok.
- Otherwise returns error: "Language '{lang}' is not supported"
- get_lang() -> &'static LanguageIdentifier
- Returns the initialized language or panics if not set
- get_default_lang() -> &'static LanguageIdentifier
- Reads env in order: LC_ALL, LC_MESSAGES, LANG; defaults to "en_us"
- Lowercases the value
- Returns the first supported language that matches current prefix (current.starts_with(lang.language))
- If none match, returns FALLBACK
- format_lang(lang: &LanguageIdentifier) -> String
- Returns "language-region" with region lowercased if present; otherwise just language
- Translation macro
- tr!(id) -> LOCALES.lookup(get_lang(), id)
- tr!(id, { "key" = value, ... }) -> builds HashMap<String, FluentValue> and calls LOCALES.lookup_complete(get_lang(), id, Some(&args))
- Requires: use fluent_templates::Loader
- Examples in docs show usage without and with parameters
- Notes
- Default language env value in code is "en_us" (underscore) before normalization
- get_default_lang uses language prefix matching against lang.language component (e.g., "en" matches "en-us")# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev ca-certificates \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy manifest first to leverage build cache
COPY Cargo.toml Cargo.lock ./
RUN cargo fetch
# Copy the rest of the source
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 libGL1
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary from builder
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Ensure binary is executable
RUN chmod +x /usr/local/bin/anime-game-launcher
CMD ["anime-game-launcher"]
Concerns: COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher is executed in the final stage after USER appuser has been set, which means the copy will attempt to write to /usr/local/bin as a non-root user. This will likely fail due to insufficient permissions., To fix, copy should be performed as root (move USER appuser after the COPY), or copy to a path writable by the non-root user (e.g., /home/appuser/bin) and adjust PATH accordingly., Running a GUI app in a headless container may require an X11/Wayland server or a virtual framebuffer; smoke tests may not exercise the GUI and could be misleading in environments without display support.
# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev libglib2.0-dev libpango-1.0-dev libcairo2-dev \
libfontconfig1-dev libgdk-pixbuf2.0-dev \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy the entire repository
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 libGL1 \
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary from builder
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Copy assets directory needed by runtime (locales, icons, etc.)
COPY --from=builder /app/assets /home/appuser/assets
# Ensure binary is executable
RUN chmod +x /usr/local/bin/anime-game-launcher
CMD ["anime-game-launcher"]
Build status: build_failed Two failing steps (exit code 100) with missing packages in Ubuntu 22.04 jammy base. 1) Failing step: runtime stage - Command: RUN apt-get update && apt-get install -y --no-install-recommends libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 fonts-dejavu-core libcairo2 libfontconfig1 libGL1 && rm -rf /var/lib/apt/lists/* - Exit code: 100 - Exact error: E: Unable to locate package libGL1 - Dockerfile reference: Dockerfile:6 - Failing command: The RUN in the runtime stage that installs the listed libraries including libGL1 2) Failing step: builder stage - Command: RUN apt-get update && apt-get install -y --no-install-recommends build-essential pkg-config git curl protobuf-compiler libprotobuf-dev libgtk-4-dev libadwaita-1-dev libglib2.0-dev libpango-1.0-dev libcairo2-dev libfontconfig1-dev libgdk-pixbuf2.0-dev && rm -rf /var/lib/apt/lists/* - Exit code: 100 - Exact errors: - E: Unable to locate package libpango-1.0-dev - E: Couldn't find any package by glob 'libpango-1.0-dev' - E: Couldn't find any package by regex 'libpango-1.0-dev' - Failing command: The RUN in the builder stage that installs the listed dev packages including libpango-1.0-dev Missing packages/files - libGL1: not found by apt in the runtime stage - libpango-1.0-dev: not found by apt in the builder stage (glob/regex) Version/compat notes - Base image: Ubuntu 22.04 (jammy) as referenced by Dockerfile: FROM ubuntu:22.04 with a specific sha - Errors indicate package-name availability/matching issues for jammy, not a download failure Other notes - Summary indicates package availability/name mismatch for the specified distro.
# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \
libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf2.0-dev \
libpango1.0-dev libcairo2-dev libfontconfig1-dev \
&& rm -rf /var/lib/apt/lists/*
# Install Rust
RUN curl -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy the entire repository
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 libgl1 \
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary and assets from builder
COPY --from=builder --chown=appuser:appuser /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
COPY --from=builder --chown=appuser:appuser /app/assets /home/appuser/assets
RUN chmod +x /usr/local/bin/anime-game-launcher
CMD ["anime-game-launcher"]
- Exact error message and exit code
- /bin/sh: 1: cargo: not found
- Exit code: 127
- Failing command/step
- [builder 6/6] RUN cargo build --release
- Dockerfile line: RUN cargo build --release
- Missing packages or files mentioned
- cargo binary not found (Rust toolchain did not install or is unavailable)
- Related evidence: earlier step attempted to install Rust via curl from rustup (step showing: “curl -sSf https://sh.rustup.rs | sh -s -- -y”), but encountered a certificate error:
- curl: (77) error setting certificate file: /etc/ssl/certs/ca-certificates.crt
- Version mismatch information
- No explicit version mismatch is shown. Base image is ubuntu:22.04, and the final blocker is that cargo is not available due to the failed Rust toolchain install (certificate issue preventing rustup from completing).# Multi-stage Dockerfile for anime-game-launcher
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl ca-certificates protobuf-compiler \
libprotobuf-dev libgtk-4-dev libadwaita-1-dev libglib2.0-dev \
libgdk-pixbuf2.0-dev libpango1.0-dev libcairo2-dev libfontconfig1-dev \
fonts-dejavu-core libwayland-client0-dev libwayland-egl1-dev libx11-dev \
&& rm -rf /var/lib/apt/lists/*
# Install Rust toolchain via rustup
RUN curl -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig
WORKDIR /app
# Copy manifest first to leverage build cache
COPY Cargo.toml Cargo.lock ./
RUN cargo fetch
# Copy the rest of the source
COPY . .
# Build the project
RUN cargo build --release
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \
libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \
fonts-dejavu-core libcairo2 libfontconfig1 libgl1 \
&& rm -rf /var/lib/apt/lists/*
# Create non-root user
RUN useradd -m appuser
USER appuser
WORKDIR /home/appuser
# Copy built binary and assets from builder
COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
COPY --from=builder /app/assets /home/appuser/assets
# Ensure binary is executable
RUN chmod +x /usr/local/bin/anime-game-launcher
CMD ["anime-game-launcher"]
Summary of Docker build error
- Failing step (command/step):
[builder 2/8] RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential pkg-config git curl ca-certificates protobuf-compiler \
libprotobuf-dev libgtk-4-dev libadwaita-1-dev libglib2.0-dev \
libgdk-pixbuf2.0-dev libpango1.0-dev libcairo2-dev libfontconfig1-dev \
fonts-dejavu-core libwayland-client0-dev libwayland-egl1-dev libx11-dev \
&& rm -rf /var/lib/apt/lists/*
- Exact error message and exit code:
- E: Unable to locate package libwayland-client0-dev
- E: Unable to locate package libwayland-egl1-dev
- Exit code: 100
- Missing packages or files mentioned:
- libwayland-client0-dev
- libwayland-egl1-dev
- Version mismatch information:
- No explicit version mismatch is reported. The base image is Ubuntu 22.04 (jammy), and apt-get fetches jammy repositories, but the two Wayland development packages cannot be located in those repos. This indicates missing or renamed packages for the jammy release rather than a clearly stated version mismatch.
Additional context:
- The error occurs during builder stage 2/8 of the Dockerfile, in the RUN apt-get update && apt-get install -y ... step.
- The log shows the base image as ubuntu:22.04 and that the two libwayland-...-dev packages are the ones not found.# Multi-stage Dockerfile for anime-game-launcher FROM ubuntu:22.04 AS builder ENV DEBIAN_FRONTEND=noninteractive RUN apt-get update && apt-get install -y --no-install-recommends \ build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \ libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf2.0-dev \ libpango1.0-dev libcairo2-dev libfontconfig1-dev fonts-dejavu-core \ rustc cargo ca-certificates WORKDIR /app # Copy the entire repository COPY . . # Build the project using system Rust RUN cargo build --release FROM ubuntu:22.04 AS runtime ENV DEBIAN_FRONTEND=noninteractive RUN apt-get update && apt-get install -y --no-install-recommends \ libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \ libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \ fonts-dejavu-core libcairo2 libfontconfig1 libgl1 \ && rm -rf /var/lib/apt/lists/* RUN useradd -m appuser USER appuser WORKDIR /home/appuser # Copy the built binary and assets from builder COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher COPY --from=builder /app/assets /home/appuser/assets RUN chmod +x /usr/local/bin/anime-game-launcher CMD ["anime-game-launcher"]
Concerns: COPY commands run after USER appuser; appuser cannot write to /usr/local/bin and /home/appuser/assets during image build, causing permission errors. COPY should run as root before switching to the non-root user or adjust ownership after copy., Potential mismatch: the runtime assumes a binary named anime-game-launcher; ensure Cargo.toml crate name produces that binary in target/release., No explicit chown after COPY; best practice is to copy as root and then chown -R appuser:appuser /usr/local/bin/anime-game-launcher /home/appuser/assets.
# Multi-stage Dockerfile for anime-game-launcher FROM ubuntu:22.04 AS builder ENV DEBIAN_FRONTEND=noninteractive RUN apt-get update && apt-get install -y --no-install-recommends \ build-essential pkg-config git curl protobuf-compiler libprotobuf-dev \ libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf2.0-dev \ libpango1.0-dev libcairo2-dev libfontconfig1-dev fonts-dejavu-core \ rustc cargo ca-certificates WORKDIR /app # Copy the entire repository COPY . . # Build the project using system Rust RUN cargo build --release FROM ubuntu:22.04 AS runtime ENV DEBIAN_FRONTEND=noninteractive RUN apt-get update && apt-get install -y --no-install-recommends \ libgtk-4-1 libadwaita-1-0 libglib2.0-0 libpango-1.0-0 \ libgdk-pixbuf2.0-0 libwayland-client0 libwayland-egl1 libx11-6 \ fonts-dejavu-core libcairo2 libfontconfig1 libgl1 \ && rm -rf /var/lib/apt/lists/* # Create non-root user and switch to it RUN useradd -m appuser # Copy built binary and assets from builder (run as root for copy, then chown) COPY --from=builder /app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher COPY --from=builder /app/assets /home/appuser/assets # Change ownership to non-root user RUN chown -R appuser:appuser /usr/local/bin/anime-game-launcher /home/appuser/assets USER appuser WORKDIR /home/appuser RUN chmod +x /usr/local/bin/anime-game-launcher CMD ["anime-game-launcher"]
Concerns: - COPY --from=builder /app/assets may fail if assets directory is missing in the repository. - Running the GUI launcher may require a display/server; smoke tests should avoid launching the UI. Build step: - [builder 2/5] RUN apt-get update && apt-get install -y --no-install-recommends build-essential pkg-config git curl protobuf-compiler libprotobuf-dev libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf2.0-dev libpango1.0-dev libcairo2-dev libfontconfig1-dev fonts-dejavu-core rustc cargo ca-certificates Exact error and exit code: - ERROR: failed to build: failed to solve: process "/bin/sh -c apt-get update && apt-get install -y --no-install-recommends build-essential pkg-config git curl protobuf-compiler libprotobuf-dev libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf2.0-dev libpango1.0-dev libcairo2-dev libfontconfig1-dev fonts-dejavu-core rustc cargo ca-certificates" did not complete successfully: exit code: 100 During apt-get install, the following errors occurred: - E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/s/systemd/libsystemd0_249.11-0ubuntu3.19_amd64.deb 404 Not Found [IP: 91.189.91.83 80] - E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/s/systemd/systemd_249.11-0ubuntu3.19_amd64.deb 404 Not Found [IP: 91.189.91.83 80] - E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/s/systemd/systemd-sysv_249.11-0ubuntu3.19_amd64.deb 404 Not Found [IP: 91.189.91.83 80] - E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/s/systemd/libpam-systemd_249.11-0ubuntu3.19_amd64.deb 404 Not Found [IP: 91.189.91.83 80] - E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing? Missing packages/files mentioned: - libsystemd0_249.11-0ubuntu3.19_amd64.deb - systemd_249.11-0ubuntu3.19_amd64.deb - systemd-sysv_249.11-0ubuntu3.19_amd64.deb - libpam-systemd_249.11-0ubuntu3.19_amd64.deb Version mismatch info: - The log shows a planned upgrade to libsystemd0, systemd, systemd-sysv, libpam-systemd to version 249.11-0ubuntu3.19, but those exact package files are not available (404). This indicates a repository/metadata mismatch for jammy-security, causing apt to fail fetching required systemd-related packages during the install. Recommendation / next steps: - apt-get update or use --fix-missing? (as suggested in the log) - Check jammy-security repository metadata and package availability for 249.11-0ubuntu3.19.