FROM rust:1.94.0 as builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev \
libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
# Copy source
COPY . .
# Build release
RUN cargo build --release
# Runtime stage
FROM debian:bookworm-slim
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 && \
rm -rf /var/lib/apt/lists/*
# Copy the binary from builder
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Run the GUI launcher (needs display forwarding to work)
CMD ["/usr/local/bin/anime-game-launcher"]
target/ **/.git .git/ node_modules/ vendor/ .DS_Store *.log *.tmp build/ *.rs.bk Cargo.lock
Summary (under 1500 chars):
- Exact error message and exit code
- E: Unable to locate package libgtk-4-4
- E: Unable to locate package libadwaita-1
- The build failure: ERROR: failed to build: failed to solve: process "/bin/sh -c apt-get update && apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100
- Failing command/step
- Stage-1 2/3: RUN apt-get update && apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 && rm -rf /var/lib/apt/lists/*
- Missing packages or files mentioned
- libgtk-4-4
- libadwaita-1
- Version mismatch info
- Base images involved:
- Stage-1 FROM docker.io/library/debian:bookworm-slim@sha256:f065... (Debian bookworm-slim)
- Builder FROM docker.io/library/rust:1.94.0@sha256:7272... (Rust 1.94.0)
- The error arises while installing GUI libraries on Debian bookworm-slim, suggesting these package names are not available in the used Debian repos for this image variant.FROM rust:1.94.0 as builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
# Copy source
COPY . .
# Build release
RUN cargo build --release
# Runtime stage
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
apt-get install -y --no-install-recommends \
libgtk-4-4 libadwaita-1 \
&& \
rm -rf /var/lib/apt/lists/*
# Copy the binary from builder
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Run the GUI launcher (needs display forwarding to work)
CMD ["/usr/local/bin/anime-game-launcher"]
Summary (under 1500 chars): - Exit code: 100 - Failing command/step: [stage-1 2/3] RUN apt-get update && apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 && rm -rf /var/lib/apt/lists/* - Exact error messages: - E: Unable to locate package libgtk-4-4 - E: Unable to locate package libadwaita-1 - Missing packages or files mentioned: - libgtk-4-4 - libadwaita-1 (These packages could not be found in the Ubuntu jammy repositories during apt-get install) - Version mismatch info: - No explicit version mismatch reported. - Base images in use (as shown in logs): ubuntu:22.04 and rust:1.94.0 (with associated sha256 digests).
FROM rust:1.94.0 as builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
# Copy source
COPY . .
# Build release
RUN cargo build --release
# Runtime stage
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libpango-1.0-0 libcairo2 ca-certificates shared-mime-info \
&& \
rm -rf /var/lib/apt/lists/*
# Copy the binary from builder
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Run the GUI launcher (needs display forwarding to work)
CMD ["/usr/local/bin/anime-game-launcher"]
Summary: - Exact error message and exit code - The build failed with exit code 100 during a RUN step: “ERROR: failed to build: failed to solve: process "/bin/sh -c apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libpango-1.0-0 libcairo2 ca-certificates shared-mime-info && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100” - Failing command/step - [stage-1 2/3] RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libpango-1.0-0 libcairo2 ca-certificates shared-mime-info && rm -rf /var/lib/apt/lists/* - Missing packages or files mentioned - E: Unable to locate package libgtk-4-4 - E: Unable to locate package libadwaita-1 - Version mismatch information - Base image: ubuntu:22.04 (jammy) - GTK4 runtime package name used in the Dockerfile appears incorrect for Jammy (libgtk-4-4 does not exist there). The GTK4 runtime is typically libgtk-4-1, indicating a packaging/name mismatch with the Ubuntu 22.04 repos. - Other notable context - Initial warning: FromAsCasing: 'as' and 'FROM' keywords' casing do not match (line 1)
FROM rust:1.94.0 as builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy source and build in release mode
COPY Cargo.toml Cargo.lock ./
COPY . ./
RUN cargo build --release
# Runtime stage
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info \
&& \
rm -rf /var/lib/apt/lists/*
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Run the GUI launcher (note: may require X11/Wayland forwarding in runtime)
CMD ["/usr/local/bin/anime-game-launcher"]
Summary (under 1500 chars): - Exact error message and exit code - E: Unable to locate package libadwaita-1 - Exit code: 100 - Failing command/step - Stage-1 (2/3) RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends libgtk-4-1 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info && rm -rf /var/lib/apt/lists/* - Missing packages or files mentioned - libadwaita-1 (not found) - Version mismatch / notable context - Base images shown: rust:1.94.0 and ubuntu:22.04 - The apt output for this stage references Debian trixie repositories (deb.debian.org, trixie) despite the stage originating from an Ubuntu base, indicating a package-source/version mismatch. - Warning observed: "FromAsCasing: 'as' and 'FROM' keywords' casing do not match (line 1)" (one warning) - This mismatch likely causes the missing libadwaita-1 package in the Ubuntu-based build step.
FROM rust:1.94.0 AS builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
COPY . ./
# Build release
RUN cargo build --release
# Runtime stage
FROM debian:bookworm-slim AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info \
&& \
rm -rf /var/lib/apt/lists/*
# Copy the binary from builder
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Run the GUI launcher (note: may require X11/Wayland forwarding in runtime)
CMD ["/usr/local/bin/anime-game-launcher"]
- Exact error message and exit code
- ERROR: process "/bin/sh -c apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100
- Failing command/step
- [runtime 2/3] RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info && rm -rf /var/lib/apt/lists/*
- Dockerfile: line with the apt-get install command for libgtk-4-4 and libadwaita-1
- Missing packages or files mentioned
- E: Unable to locate package libgtk-4-4
- E: Unable to locate package libadwaita-1
- Version mismatch information
- The build shows mixed Debian releases across stages:
- runtime uses Debian bookworm (bookworm InRelease)
- builder later uses Debian trixie (trixie InRelease)
- This indicates a Debian release mismatch (bookworm vs. trixie) that likely causes the missing-package errors for libgtk-4-4 and libadwaita-1, which are not located in the current bookworm sources but appear in the trixie sources.FROM rust:1.94.0 as builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
COPY . ./
# Build release
RUN cargo build --release
# Runtime stage
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info \
&& \
rm -rf /var/lib/apt/lists/*
# Copy the binary from builder
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Run the GUI launcher (note: may require X11/Wayland forwarding in runtime)
CMD ["/usr/local/bin/anime-game-launcher"]
Summary:
- Failing error (exact message and exit code)
- E: Unable to locate package libadwaita-1
- exit code: 100
- Failing command/step
- Step: runtime 2/3
- Command:
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends libgtk-4-1 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info && rm -rf /var/lib/apt/lists/*
- Missing packages or files mentioned
- libadwaita-1 (not found)
- Context from earlier builder step shows libadwaita-1-0 and libadwaita-1-dev were installed there, indicating a package-name/version mismatch between stages:
- libadwaita-1-0 (present in builder logs)
- libadwaita-1 (requested in runtime)
- Version/os mismatch/info
- Builder stage uses Debian trixie (APT sources shown) while the failing runtime stage uses Ubuntu jammy (22.04) repositories.
- The package name differs between these environments (libadwaita-1-0/libadwaita-1-0-dev in builder vs libadwaita-1 in runtime), suggesting a mismatch in distro/package naming across stages.[package]
name = "anime-game-launcher"
version = "3.18.0"
description = "Anime Game launcher"
authors = ["Nikita Podvirnyi <krypt0nn@vk.com>"]
homepage = "https://github.com/an-anime-team/an-anime-game-launcher"
repository = "https://github.com/an-anime-team/an-anime-game-launcher"
license = "GPL-3.0"
edition = "2021"
build = "build.rs"
[profile.release]
strip = true
lto = true
opt-level = "s"
[build-dependencies]
glib-build-tools = "0.20"
[dependencies.anime-launcher-sdk]
git = "https://github.com/an-anime-team/anime-launcher-sdk"
tag = "1.32.0"
features = ["all", "genshin"]
# path = "../anime-launcher-sdk" # ! for dev purposes only
[dependencies]
relm4 = { version = "0.9.1", features = ["macros", "libadwaita"] }
gtk = { package = "gtk4", version = "0.9.6", features = ["v4_16"] }
adw = { package = "libadwaita", version = "0.7.2", features = ["v1_5"] }
rfd = { version = "0.15.3", features = ["xdg-portal", "tokio"], default-features = false }
open = "5.3.2"
whatadistro = "0.1.0"
serde_json = "1.0"
anyhow = "1.0"
lazy_static = "1.5.0"
cached = { version = "0.55", features = ["proc_macro"] }
md-5 = { version = "0.10", features = ["asm"] }
enum-ordinalize = "4.3"
tracing = "0.1"
tracing-subscriber = "0.3"
fluent-templates = "0.13"
unic-langid = "0.9"
human-panic = "2.0.2"
No results found.
FROM rust:1.94.0 AS builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
# Copy source
COPY . .
# Build release
RUN cargo build --release
# Runtime stage: reuse the builder's OS and libraries by copying /usr and the binary
FROM debian:bookworm-slim AS runtime
ENV DEBIAN_FRONTEND=noninteractive
# Copy the prebuilt binary and the system libraries from the builder
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
COPY --from=builder /usr /usr
# Run the GUI launcher (note: will require display forwarding in real usage)
CMD ["/usr/local/bin/anime-game-launcher"]
Concerns: Copying the entire /usr directory from the builder into a different runtime image (debian bookworm-slim) can cause ABI/library mismatches or runtime incompatibilities when the base images differ. This is brittle; consider installing only the necessary runtime libraries in the final image or using a runtime base that matches the builder's libraries., The GUI launcher likely requires a display/server (X11/Wayland). In headless CI or non-GUI environments, tests may fail. Ensure smoke tests validate non-GUI behavior (e.g., --version/--help) or run with a forwarded DISPLAY when appropriate. Smoke [PASS]: test -x /usr/local/bin/anime-game-launcher Smoke [PASS]: file /usr/local/bin/anime-game-launcher | grep -q ELF Smoke [FAIL]: ldd /usr/local/bin/anime-game-launcher | grep -q 'libgtk Output: sh: 1: Syntax error: Unterminated quoted string
FROM debian:bookworm-slim AS builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
ca-certificates libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
# Copy source
COPY . .
# Build release
RUN cargo build --release
# Runtime stage is effectively the same base (no cross-stage ABI concerns here)
FROM debian:bookworm-slim
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
apt-get install -y --no-install-recommends \
libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info \
fontconfig && \
rm -rf /var/lib/apt/lists/*
# Copy the built binary from builder
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Run the GUI launcher (note: requires display forwarding to work in real usage)
CMD ["/usr/local/bin/anime-game-launcher"]
- Failing step:
- Stage: [stage-1 2/3]
- Command:
RUN apt-get update && apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info fontconfig && rm -rf /var/lib/apt/lists/*
- Exact error messages and exit code:
- E: Unable to locate package libgtk-4-4
- E: Unable to locate package libadwaita-1
- ERROR: failed to build: failed to solve: process "/bin/sh -c apt-get update && apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info fontconfig && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100
- Missing packages or files mentioned:
- libgtk-4-4
- libadwaita-1
- Version mismatch / environment notes:
- Base image is Debian bookworm-slim (from debian:bookworm-slim with a specific sha). The failure is due to missing packages in the Bookworm slim repositories, not a mismatched package version in the Dockerfile.ubuntu/dotnet-runtime (24 stars): Chiselled Ubuntu runtime image for .NET apps. Long-term tracks maintained by Can ubuntu/squid (124 stars): Squid is a caching proxy for the Web. Long-term versions maintained by Canonical ubuntu/nginx (140 stars): Nginx, a high-performance reverse proxy & web server. Long-term tracks maintaine rancher/rke2-runtime (5 stars): ubuntu/bind9 (117 stars): BIND 9 is a very flexible, full-featured DNS system. Long-term versions maintain ibm-semeru-runtimes (60 stars): IBM Semeru Runtimes Official Images for OpenJDK and Eclipse OpenJ9 binaries. ubuntu/kafka (60 stars): Apache Kafka, a distributed event streaming platform. Long-term tracks maintaine ubuntu/apache2 (102 stars): Apache, a secure & extensible open-source HTTP server. Long-term tracks maintain ubuntu/zookeeper (14 stars): ZooKeeper maintains configuration information centrally. Long-term tracks mainta ubuntu/prometheus (78 stars): Prometheus is a systems and service monitoring system. Long-term versions mainta
No results found.
FROM rust:1.94.0 AS builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
# Copy source
COPY . .
# Build release
RUN cargo build --release
# Runtime stage
FROM ubuntu:22.04 AS runtime
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
libgtk-4-1 libadwaita-1-0 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 libpango-1.0-0 fontconfig ca-certificates \
&& \
rm -rf /var/lib/apt/lists/*
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
CMD ["/usr/local/bin/anime-game-launcher"]
Concerns: Binary name assumption: the final COPY targets anime-game-launcher; if Cargo.toml defines a different binary name, the build may fail or the COPY path may be incorrect., GUI application behavior: smoke tests do not exercise the UI and may be affected by lack of a display/X server in container environments. Smoke [PASS]: test -x /usr/local/bin/anime-game-launcher Smoke [FAIL]: file /usr/local/bin/anime-game-launcher | grep -q 'ELF Output: sh: 1: Syntax error: Unterminated quoted string
FROM rust:1.94.0 AS builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential pkg-config libgtk-4-dev libadwaita-1-dev libglib2.0-dev libgdk-pixbuf-2.0-dev protobuf-compiler cmake git curl \
libssl-dev && \
rm -rf /var/lib/apt/lists/*
WORKDIR /work
# Copy manifest and lock to cache dependencies
COPY Cargo.toml Cargo.lock ./
# Copy source
COPY . .
# Build release
RUN cargo build --release
# Runtime stage
FROM debian:bookworm-slim
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info \
fontconfig && \
rm -rf /var/lib/apt/lists/*
# Copy the built binary and necessary runtime libraries from builder
COPY --from=builder /work/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
COPY --from=builder /usr/lib /usr/lib
COPY --from=builder /lib /lib
# Run the GUI launcher (note: requires display forwarding to work in real usage)
CMD ["/usr/local/bin/anime-game-launcher"]
- Exact error messages (exit code): - E: Unable to locate package libgtk-4-4 - E: Unable to locate package libadwaita-1 - Exit code: 100 - Failing command/step: - [stage-1 2/5] RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends libgtk-4-4 libadwaita-1 libglib2.0-0 libgdk-pixbuf-2.0-0 libcairo2 ca-certificates shared-mime-info fontconfig && rm -rf /var/lib/apt/lists/* - Missing packages or files mentioned: - libgtk-4-4 - libadwaita-1 - Version mismatch info: - No explicit version mismatch reported. Base images shown are rust:1.94.0 and Debian bookworm-slim; the failure occurs due to apt not locating the GTK-related packages in this Debian environment.
# Multi-stage Dockerfile to build anime-game-launcher from source and run it with GTK4
# Builder stage: compile from source with the Rust toolchain
FROM rust:1.94.0 AS builder
# Install build dependencies (GTK4 and related tooling, protobuf, OpenSSL for crates that use TLS)
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
build-essential \
pkg-config \
libgtk-4-dev \
libadwaita-1-dev \
libglib2.0-dev \
libgdk-pixbuf-2.0-dev \
protobuf-compiler \
cmake \
git \
curl \
libssl-dev \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /usr/src/app
# Cache dependencies: copy only manifest first
COPY Cargo.toml Cargo.lock ./
RUN cargo fetch
# Copy the full source and build the project
COPY . .
# Build in release mode
RUN cargo build --release
# Runtime stage: minimal image with only runtime dependencies
FROM debian:bookworm-slim AS runtime
# Install minimal GTK4 runtime and OpenSSL libraries
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
libgtk-4-1 \
libadwaita-1-0 \
libssl3 \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder
COPY --from=builder /usr/src/app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Set the command to run the GUI application
CMD ["/usr/local/bin/anime-game-launcher"]
# Docker ignore file **/target **/.git **/.gitignore Cargo.lock
- Exact error message and exit code:
- "error: failed to parse manifest at `/usr/src/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"
- Exit code: 101
- Failing command/step:
- [builder 5/7] RUN cargo fetch
- Missing packages or files mentioned:
- The manifest lacks defined targets. Cargo.toml has no targets and therefore requires either:
- a src/main.rs (binary) or src/lib.rs (library), or
- a [lib] section, or [[bin]] section in Cargo.toml
- Path shown: /usr/src/app/Cargo.toml
- Version mismatch information:
- Base image and repo mix observed:
- Dockerfile uses: FROM docker.io/library/rust:1.94.0 and Debian bookworm-slim
- apt-get steps pull from Debian "trixie" (testing) in one part of the log, then later use "bookworm" (stable) in another part
- This indicates a Debian release mismatch across build steps (trixie vs bookworm) alongside the Rust base image.# Multi-stage Dockerfile to build anime-game-launcher from source and run it with GTK4
# Builder stage: compile from source with the Rust toolchain
FROM rust:1.94.0 AS builder
# Install build dependencies (GTK4 and related tooling, protobuf, OpenSSL for crates that use TLS)
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
build-essential \
pkg-config \
libgtk-4-dev \
libadwaita-1-dev \
libglib2.0-dev \
libgdk-pixbuf-2.0-dev \
protobuf-compiler \
cmake \
git \
curl \
libssl-dev \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /usr/src/app
# Copy manifest first to leverage Docker cache (dependencies)
COPY Cargo.toml Cargo.lock ./
# Optional: fetch dependencies, but do not rely on it for build targets
RUN true
# Copy the full source
COPY . .
# Build in release mode
RUN cargo build --release
# Runtime stage: minimal image with only runtime dependencies
FROM debian:bookworm-slim AS runtime
# Install minimal GTK4 runtime and OpenSSL libraries
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
libgtk-4-1 \
libadwaita-1-0 \
libgdk-pixbuf-2.0-0 \
libcairo2 \
libpango-1.0-0 \
libglib2.0-0 \
libatk-1.0-0 \
libgdk-x11-2-0 \
libwayland-client0 \
libwayland-cursor0 \
libwayland-egl1 \
libxcb-shm0 \
libxcb-render0 \
libxcb1 \
libssl3 \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder
COPY --from=builder /usr/src/app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Expose display if needed (not strictly needed for CMD, but user can forward X11/Wayland as needed)
# Set the command to run the GUI application
CMD ["/usr/local/bin/anime-game-launcher"]
- VerifyBuild status: build_failed
- Concerns
- GUI app may not render in a headless container; smoke tests only verify the binary exists and can load libs, not the actual UI.
- Runtime runs as root by default; consider adding a non-root user for security and potential GTK runtime requirements.
- Build error
- Exact error message and exit code:
- ERROR: failed to build: failed to solve: process "/bin/sh -c apt-get update && apt-get install -y --no-install-recommends libgtk-4-1 libadwaita-1-0 libgdk-pixbuf-2.0-0 libcairo2 libpango-1.0-0 libglib2.0-0 libatk-1.0-0 libgdk-x11-2-0 libwayland-client0 libwayland-cursor0 libwayland-egl1 libxcb-shm0 libxcb-render0 libxcb1 libssl3 && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100
- Failing command/step:
- [runtime 2/3] RUN apt-get update && apt-get install -y --no-install-recommends libgtk-4-1 libadwaita-1-0 libgdk-pixbuf-2.0-0 libcairo2 libpango-1.0-0 libglib2.0-0 libatk-1.0-0 libgdk-x11-2-0 libwayland-client0 libwayland-cursor0 libwayland-egl1 libxcb-shm0 libxcb-render0 libxcb1 libssl3 && rm -rf /var/lib/apt/lists/*
- Missing packages or files mentioned
- E: Unable to locate package libatk-1-0
- E: Couldn't find any package by glob 'libatk-1.0-0'
- E: Couldn't find any package by regex 'libatk-1.0-0'
- E: Unable to locate package libgdk-x11-2-0
- Version/packaging mismatch info
- Runtime base image: debian:bookworm-slim
- Build image/base: rust:1.94.0
- The apt errors suggest Debian bookworm package name mismatches (e.g., libatk-1.0-0 vs the expected libatk1.0-0, and libgdk-x11-2-0 may be incorrect for this release). This points to a packaging/name mismatch between the requested GTK-related libraries and what is available in Debian bookworm repositories.# Multi-stage Dockerfile to build anime-game-launcher from source and run it with GTK4
# Builder stage: compile from source with the Rust toolchain
FROM rust:1.94.0 AS builder
# Install build dependencies (GTK4 and related tooling, protobuf, OpenSSL for crates that use TLS)
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
build-essential \
pkg-config \
libgtk-4-dev \
libadwaita-1-dev \
libglib2.0-dev \
libgdk-pixbuf-2.0-dev \
protobuf-compiler \
cmake \
git \
curl \
libssl-dev \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /usr/src/app
# Copy the entire repository (no pre-cached dependencies)
COPY . .
# Build in release mode
RUN cargo build --release
# Runtime stage: minimal image with only runtime dependencies
FROM ubuntu:22.04 AS runtime
# Install minimal GTK4 runtime and OpenSSL libraries
RUN apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
libgtk-4-1 \
libadwaita-1-0 \
libgdk-pixbuf-2.0-0 \
libcairo2 \
libpango-1.0-0 \
libglib2.0-0 \
libatk1.0-0 \
libwayland-client0 \
libwayland-cursor0 \
libwayland-egl1 \
libxcb-shm0 \
libxcb-render0 \
libxcb1 \
libssl3 \
&& rm -rf /var/lib/apt/lists/*
# Copy the built binary from the builder
COPY --from=builder /usr/src/app/target/release/anime-game-launcher /usr/local/bin/anime-game-launcher
# Set the command to run the GUI application
CMD ["/usr/local/bin/anime-game-launcher"]
Concerns: Runtime image does not install ca-certificates; TLS connections (if the app makes network requests) may fail without CA certs., No non-root user is configured for the runtime container; GUI apps typically should run as a non-privileged user., Smoke tests do not exercise actual GUI rendering (display server issues). Consider adding headless checks or a Wayland/Xvfb test if needed. Smoke [PASS]: test -x /usr/local/bin/anime-game-launcher Smoke [PASS]: ldd /usr/local/bin/anime-game-launcher | head -n 5