|
| 1 | +# To create and run the docker container in PowerShell or BASH: |
| 2 | +# |
| 3 | +# $ cd /path/to/project/root/mayaMatchMoveSolver/ |
| 4 | +# $ docker build --file share/docker/Dockerfile_maya2026 -t mmsolver-linux-maya2026-build . |
| 5 | +# $ docker run --rm --interactive --volume "${PWD}:/mmSolver" --tty mmsolver-linux-maya2026-build bash |
| 6 | +# |
| 7 | +# |
| 8 | +# Once the docker image is built and run, you can execute the |
| 9 | +# following... |
| 10 | +# |
| 11 | +# |
| 12 | +# Install Python and run tools: |
| 13 | +# |
| 14 | +# $ source ./scripts/python_venv_activate_maya2026.bash |
| 15 | +# $ ./scripts/python_linter_run_pylint.bash |
| 16 | +# $ ./scripts/python_linter_run_flake8.bash |
| 17 | +# $ ./scripts/python_linter_run_cpplint.bash |
| 18 | +# $ ./scripts/python_formatter_run_black_check.bash |
| 19 | +# $ deactivate |
| 20 | +# |
| 21 | +# |
| 22 | +# Build CMake project: |
| 23 | +# |
| 24 | +# $ ./scripts/build_mmSolver_linux_maya2026.bash |
| 25 | +# $ mayapy tests/runTests.py |
| 26 | +# |
| 27 | + |
| 28 | +FROM rockylinux:8 |
| 29 | + |
| 30 | +# Maya documentation for installing on RHEL8 / Rocky8: |
| 31 | +# https://help.autodesk.com/view/MAYAUL/2025/ENU/?guid=GUID-D2B5433C-E0D2-421B-9BD8-24FED217FD7F |
| 32 | +# |
| 33 | +# And this forum post: |
| 34 | +# https://forums.autodesk.com/t5/maya-forum/install-maya-2023-update-3-on-rocky-linux-8-7-instructions/td-p/11735138 |
| 35 | + |
| 36 | +# Install Extra Packages Enterprise Linux (EPEL) repo for extra tools. |
| 37 | +RUN dnf install --assumeyes https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm \ |
| 38 | + && dnf install --assumeyes epel-release \ |
| 39 | + && dnf update --assumeyes \ |
| 40 | + && dnf makecache |
| 41 | + |
| 42 | +# General packages |
| 43 | +RUN dnf install --assumeyes \ |
| 44 | + glibc \ |
| 45 | + libSM \ |
| 46 | + libICE \ |
| 47 | + zlib \ |
| 48 | + openssl-libs \ |
| 49 | + nss \ |
| 50 | + libnsl \ |
| 51 | + dbus \ |
| 52 | + redhat-lsb-core \ |
| 53 | + pcre-utf16 \ |
| 54 | + pciutils \ |
| 55 | + libXdamage |
| 56 | + |
| 57 | +# Multimedia Packages |
| 58 | +RUN dnf install --assumeyes \ |
| 59 | + mesa-libGL \ |
| 60 | + mesa-libGL-devel \ |
| 61 | + mesa-libGLU \ |
| 62 | + mesa-libGLw \ |
| 63 | + gamin \ |
| 64 | + audiofile-devel \ |
| 65 | + e2fsprogs-libs \ |
| 66 | + libcap \ |
| 67 | + libdrm \ |
| 68 | + libmng \ |
| 69 | + speech-dispatcher \ |
| 70 | + cups \ |
| 71 | + libpng15 |
| 72 | + |
| 73 | +# X Window – Xcb – X11 Packages |
| 74 | +RUN dnf install --assumeyes \ |
| 75 | + libX11 \ |
| 76 | + libXScrnSaver \ |
| 77 | + libXau \ |
| 78 | + libXcomposite \ |
| 79 | + libXcursor \ |
| 80 | + libXext \ |
| 81 | + libXfixes \ |
| 82 | + libXi \ |
| 83 | + libXinerama \ |
| 84 | + libXmu \ |
| 85 | + libXp \ |
| 86 | + libXpm \ |
| 87 | + libXrandr \ |
| 88 | + libXrender \ |
| 89 | + libXt \ |
| 90 | + libXtst \ |
| 91 | + libxcb \ |
| 92 | + libxkbcommon \ |
| 93 | + libxkbcommon-x11 \ |
| 94 | + libxshmfence \ |
| 95 | + xcb-util \ |
| 96 | + xcb-util-image \ |
| 97 | + xcb-util-keysyms \ |
| 98 | + xcb-util-renderutil \ |
| 99 | + xcb-util-wm \ |
| 100 | + xorg-x11-server-Xorg \ |
| 101 | + xorg-x11-server-Xvfb |
| 102 | + |
| 103 | +# Install fonts needed by Maya. |
| 104 | +# This is probably only needed by the GUI (which we will not open), |
| 105 | +# but it's good to have everything needed, just in case. |
| 106 | +RUN dnf install --assumeyes \ |
| 107 | + fontconfig \ |
| 108 | + freetype \ |
| 109 | + xorg-x11-fonts-ISO8859-1-100dpi \ |
| 110 | + xorg-x11-fonts-ISO8859-1-75dpi \ |
| 111 | + liberation-mono-fonts \ |
| 112 | + liberation-fonts-common \ |
| 113 | + liberation-sans-fonts \ |
| 114 | + liberation-serif-fonts |
| 115 | + |
| 116 | +# OpenSource "mesa" OpenGL Driver. |
| 117 | +RUN dnf install --assumeyes \ |
| 118 | + mesa-libGLw \ |
| 119 | + mesa-libGLU \ |
| 120 | + mesa-libGL-devel \ |
| 121 | + mesa-libEGL-devel \ |
| 122 | + mesa-libGLES-devel \ |
| 123 | + mesa-libGLU-devel \ |
| 124 | + mesa-libGLw-devel \ |
| 125 | + libglvnd \ |
| 126 | + libglvnd-opengl \ |
| 127 | + libglvnd-egl \ |
| 128 | + libglvnd-glx \ |
| 129 | + libglvnd-gles \ |
| 130 | + libglvnd-core-devel \ |
| 131 | + libglvnd-devel |
| 132 | + |
| 133 | +# Install latest stable Rust with 'rustup'. |
| 134 | +# |
| 135 | +# TODO: Define a minimum Rust version to install. |
| 136 | +RUN curl https://sh.rustup.rs -sSf | sh -s -- -y \ |
| 137 | + && source ${HOME}/.cargo/env |
| 138 | +ENV PATH=/root/.cargo/bin:$PATH |
| 139 | + |
| 140 | +# Development tools for Maya 2026. |
| 141 | +RUN dnf install --assumeyes \ |
| 142 | + git \ |
| 143 | + python39 \ |
| 144 | + cmake \ |
| 145 | + clang-tools-extra \ |
| 146 | + gcc-toolset-11 |
| 147 | + |
| 148 | +# Install Maya from archive. |
| 149 | +ADD ./external/archives/Autodesk_Maya_2026_ML_Linux_64bit.tgz /temp |
| 150 | +# 'rpm --force' is needed to override the dependency conflict of using |
| 151 | +# 'tcl' (which is required by 'gcc-toolset-11', because it's a |
| 152 | +# "software collection" using environment modules written in tcl). |
| 153 | +RUN rpm -Uvh --force /temp/Packages/Maya2026*.rpm && rm -r /temp |
| 154 | +ENV MAYA_LOCATION=/usr/autodesk/maya/ |
| 155 | +ENV PATH=$MAYA_LOCATION/bin:$PATH |
| 156 | + |
| 157 | +# Workaround for Maya "Segmentation fault (core dumped)" issue. |
| 158 | +# See https://forums.autodesk.com/t5/maya-general/render-crash-on-linux/m-p/5608552/highlight/true |
| 159 | +ENV MAYA_DISABLE_CIP=1 |
| 160 | + |
| 161 | +WORKDIR /mmSolver |
| 162 | + |
| 163 | +# Maya 2026 development environment. |
| 164 | +ENTRYPOINT [ "scl", "enable", "gcc-toolset-11" ] |
0 commit comments