-
Notifications
You must be signed in to change notification settings - Fork 12
/
puffer-deps.dockerfile
76 lines (67 loc) · 2.84 KB
/
puffer-deps.dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
FROM pufferai/base:2.0
RUN apt-get update && \
apt-get install --no-install-recommends -y \
# Avalon
# libegl-dev libglew-dev libglfw3-dev \
# libopengl-dev libosmesa6 mesa-utils-extra \
# NetHack
clang autoconf libtool flex bison libbz2-dev \
# Griddly
libgl1-mesa-glx \
# Gym MicroRTS
openjdk-8-jdk \
# Deepmind lab Bazel
apt-transport-https curl gnupg \
# Deepmind control rendering
# Note - no libglew2.0?
libglfw3 libglew-dev \
# Bazel dependencies
build-essential freeglut3 gettext git libffi-dev libglu1-mesa \
libglu1-mesa-dev libjpeg-dev liblua5.1-0-dev libosmesa6-dev \
libsdl2-dev lua5.1 pkg-config python-setuptools python3-dev \
software-properties-common unzip zip zlib1g-dev g++ \
&& apt clean \
&& rm -rf /var/lib/apt/lists/*
RUN pip3 install wheel
# Broken as of latest Python -- let me know if you actually need this
# Install Bazel
#RUN curl -fsSL https://bazel.build/bazel-release.pub.gpg | gpg --dearmor > bazel.gpg \
# && mv bazel.gpg /etc/apt/trusted.gpg.d/ \
# && echo "deb [arch=amd64] https://storage.googleapis.com/bazel-apt stable jdk1.8" | tee /etc/apt/sources.list.d/bazel.list \
# && apt-get update && apt-get install --no-install-recommends -y bazel \
# && apt clean \
# && rm -rf /var/lib/apt/lists/*
# Install Deepmind Lab
#RUN rm -rf deepmind_lab \
# && git clone https://github.com/deepmind/lab.git deepmind_lab \
# && cd deepmind_lab \
# && echo 'build --cxxopt=-std=c++17' > .bazelrc \
# && bazel build -c opt //python/pip_package:build_pip_package \
# && ./bazel-bin/python/pip_package/build_pip_package /tmp/dmlab_pkg \
# && pip3 install --force-reinstall /tmp/dmlab_pkg/deepmind_lab-*.whl \
# && rm -rf /tmp/dmlab_pkg/deepmind_lab-*.whl \
# && rm -rf .git \
# && cd .. \
# && rm -rf ~/.cache/bazel/ \
# && rm -rf deepmind_lab
# Install Neovim and VimPlug
RUN apt update \
&& apt install -y ninja-build gettext cmake unzip curl \
&& git clone --single-branch --depth=1 https://github.com/neovim/neovim \
&& cd neovim \
&& make CMAKE_BUILD_TYPE=Release \
&& make install \
&& ln -s /usr/local/bin/nvim /usr/bin/nvim \
&& pip3 install pynvim \
&& sh -c 'curl -fLo "${XDG_DATA_HOME:-$HOME/.local/share}"/nvim/site/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
RUN git clone --recursive https://github.com/PufferAI/gpudrive \
&& cd gpudrive \
&& mkdir build \
&& cd build \
&& cmake .. -DCMAKE_BUILD_TYPE=Release \
&& make -j # cores to build with, e.g. 32 \
&& mv gpudrive.cpython-310-x86_64-linux-gnu.so gpudrive.cpython-311-x86_64-linux-gnu.so \
&& cd .. \
&& pip install -e . \
&& ln -s pygpudrive ../pufferlib/pygpudrive
# Avalon -- TODO: Figure out how to autoselect libnvidia-gl version