Files
boxsim-fileformat-rev/Dockerfile
T
magdevandClaude Fable 5 d173328443 Point library references at the new Gitea home
kicad-visaton-lib moved to
ssh://git@src.bundespruefstelle.ch:2022/magdev/kicad-visaton-lib.git.

Also corrects the image source label, which named a repository that does not
exist: this repo is magdev/boxsim-fileformat-rev, not boxdev/re-boxsim.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-29 12:23:43 +02:00

42 lines
1.5 KiB
Docker

# boxsim: decode Boxsim projects and generate KiCad projects from them.
#
# The image deliberately contains no KiCad and no Boxsim.exe:
# - KiCad 10 is a hard dependency of the *verification* gate only, and stays
# on the host. decode/extract/netlist/build all work without it.
# - The A2F codec is pure Python, so Boxsim's proprietary binary is not needed.
#
# Build via tools/build-image.sh, which stages the Visaton library and the
# Boxsim parts catalogue into the build context.
FROM python:3.13-slim AS base
LABEL org.opencontainers.image.title="boxsim" \
org.opencontainers.image.description="Boxsim project decoder and KiCad project generator" \
org.opencontainers.image.source="https://src.bundespruefstelle.ch/magdev/boxsim-fileformat-rev" \
org.opencontainers.image.licenses="MIT"
WORKDIR /opt/boxsim
COPY pyproject.toml README.md ./
COPY boxsim ./boxsim
# Staged by tools/build-image.sh: the upgraded Visaton symbol library and the
# Visaton parts catalogue shipped with Boxsim.
COPY stage/Visaton.kicad_sym ./boxsim/data/Visaton.kicad_sym
COPY stage/Visatonteile.txt ./boxsim/data/Visatonteile.txt
COPY stage/footprints ./boxsim/data/footprints
COPY tools/selfcheck.py ./tools/selfcheck.py
RUN pip install --no-cache-dir .
ENV BOXSIM_CATALOG=/opt/boxsim/boxsim/data/Visatonteile.txt \
BOXSIM_KICAD_LIB=/opt/boxsim/boxsim/data/Visaton.kicad_sym
# Refuse to produce an image whose bundled library does not cover the catalogue.
RUN python tools/selfcheck.py
WORKDIR /work
ENTRYPOINT ["boxsim"]
CMD ["--help"]