Add Docker configuration for conda.
This commit is contained in:
committed by
Adrián Insaurralde Avalos
parent
7b962e609d
commit
0ac0882eeb
18
tools/build/Docker/Dockerfile.Conda
Normal file
18
tools/build/Docker/Dockerfile.Conda
Normal file
@@ -0,0 +1,18 @@
|
||||
FROM ubuntu:22.04
|
||||
|
||||
RUN DEBIAN_FRONTEND=noninteractive apt-get update && \
|
||||
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
|
||||
ca-certificates \
|
||||
curl \
|
||||
&& \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# install Miniforge3
|
||||
RUN curl -L -O "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh" && \
|
||||
bash Miniforge3-$(uname)-$(uname -m).sh -b -p /opt/miniforge3 && \
|
||||
rm "Miniforge3-$(uname)-$(uname -m).sh" && \
|
||||
/opt/miniforge3/bin/conda init
|
||||
|
||||
WORKDIR /builds
|
||||
|
||||
VOLUME [ "/builds" ]
|
||||
26
tools/build/Docker/README.conda.rst
Normal file
26
tools/build/Docker/README.conda.rst
Normal file
@@ -0,0 +1,26 @@
|
||||
========================
|
||||
FreeCAD build with Conda
|
||||
========================
|
||||
|
||||
Container
|
||||
=========
|
||||
|
||||
Build and run the `freecad-conda` container with the following commands:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
docker build --file tools/build/Dockerfile.Conda --tag freecad-conda
|
||||
docker run --rm --interactive --tty --volume $(pwd):/builds:z freecad-conda
|
||||
|
||||
Build Code
|
||||
==========
|
||||
|
||||
Within the `freecad-conda` container, install the build dependencies and build
|
||||
FreeCAD using the following commands:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
conda/setup-environment.sh
|
||||
conda activate freecad
|
||||
cmake --preset conda-linux-debug
|
||||
cmake --build build/debug
|
||||
Reference in New Issue
Block a user