@@ -8,9 +8,15 @@ ARG WEBOTS_PACKAGE_PREFIX=
8
8
# Disable dpkg/gdebi interactive dialogs
9
9
ENV DEBIAN_FRONTEND=noninteractive
10
10
11
- RUN apt-get update && apt-get install --yes wget bzip2 && rm -rf /var/lib/apt/lists/ && \
12
- wget https://github.com/cyberbotics/webots/releases/download/$WEBOTS_VERSION/webots-$WEBOTS_VERSION-x86-64$WEBOTS_PACKAGE_PREFIX.tar.bz2 && \
13
- tar xjf webots-*.tar.bz2 && rm webots-*.tar.bz2
11
+ RUN apt-get update
12
+ RUN apt-get install --yes \
13
+ wget\
14
+ bzip2
15
+
16
+ RUN rm -rf /var/lib/apt/lists/
17
+ RUN wget https://github.com/cyberbotics/webots/releases/download/$WEBOTS_VERSION/webots-$WEBOTS_VERSION-x86-64$WEBOTS_PACKAGE_PREFIX.tar.bz2
18
+ RUN tar xjf webots-*.tar.bz2
19
+ RUN rm webots-*.tar.bz2
14
20
15
21
FROM ${BASE_IMAGE}
16
22
@@ -19,13 +25,25 @@ ENV DEBIAN_FRONTEND=noninteractive
19
25
20
26
21
27
# Install Webots runtime dependencies
22
- RUN apt-get update && apt-get install --yes wget xvfb git python3-pip sudo && rm -rf /var/lib/apt/lists/ && \
23
- wget https://raw.githubusercontent.com/cyberbotics/webots/master/scripts/install/linux_runtime_dependencies.sh && \
24
- chmod +x linux_runtime_dependencies.sh && ./linux_runtime_dependencies.sh && rm ./linux_runtime_dependencies.sh
28
+ RUN apt-get update
29
+ RUN apt-get install --yes \
30
+ wget \
31
+ xvfb \
32
+ git \
33
+ python3-pip
34
+
35
+ RUN rm -rf /var/lib/apt/lists/
36
+ RUN wget https://raw.githubusercontent.com/cyberbotics/webots/master/scripts/install/linux_runtime_dependencies.sh
37
+ RUN chmod +x linux_runtime_dependencies.sh
38
+ RUN ./linux_runtime_dependencies.sh
39
+ RUN rm ./linux_runtime_dependencies.sh
25
40
26
41
# Install NUWebots dependencies
27
- RUN wget https://raw.githubusercontent.com/NUbots/NUWebots/main/webots-docker/dependencies.sh && \
28
- chmod +x dependencies.sh && ./dependencies.sh && rm ./dependencies.sh && rm -rf /var/lib/apt/lists/
42
+ RUN wget https://raw.githubusercontent.com/NUbots/NUWebots/williamson/webots-docker/webots-docker/dependencies.sh
43
+ RUN chmod +x dependencies.sh
44
+ RUN ./dependencies.sh
45
+ RUN rm ./dependencies.sh
46
+ RUN rm -rf /var/lib/apt/lists/
29
47
30
48
# Install Webots
31
49
WORKDIR /usr/local
@@ -37,29 +55,33 @@ ENV PATH /usr/local/webots:${PATH}
37
55
# Enable OpenGL capabilities
38
56
ENV NVIDIA_DRIVER_CAPABILITIES=graphics
39
57
40
- RUN useradd -ms /bin/bash webots && usermod -aG sudo webots && echo "webots ALL=(ALL:ALL) NOPASSWD: ALL" >> /etc/sudoers
41
- ENV HOME=/home/webots
42
- USER webots
58
+ # RUN useradd -ms /bin/bash webots && usermod -aG sudo webots && echo "webots ALL=(ALL:ALL) NOPASSWD: ALL" >> /etc/sudoers
59
+ # ENV HOME=/home/webots
60
+ # USER webots
43
61
44
- WORKDIR $HOME
62
+ # WORKDIR $HOME
45
63
46
64
# Build the latest version of the RoboCup Humanoid TC fork of GameController
47
- RUN git clone https://github.com/RoboCup-Humanoid-TC/GameController ./GameController && cd GameController && ant
65
+ RUN git clone https://github.com/RoboCup-Humanoid-TC/GameController ./GameController
66
+ RUN cd GameController && ant
48
67
49
68
# Build the robocup controllers
50
- RUN git clone https://github.com/RoboCup-Humanoid-TC/hlvs_webots.git ./hlvs_webots && \
51
- pip3 install -r ./hlvs_webots/controllers/referee/requirements.txt && make -j$(nproc) -C ./hlvs_webots
69
+ RUN git clone https://github.com/RoboCup-Humanoid-TC/hlvs_webots.git ./hlvs_webots
70
+ RUN pip3 install -r ./hlvs_webots/controllers/referee/requirements.txt
71
+ RUN make -j$(nproc) -C ./hlvs_webots
52
72
53
73
# Set environment variables for GameController
54
- ENV GAME_CONTROLLER_HOME=${HOME} /GameController JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
74
+ ENV GAME_CONTROLLER_HOME=/GameController JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
55
75
56
76
# Install the NUbots-developed environment
57
- RUN git clone https://github.com/NUbots/NUWebots.git ./NUWebots && cd ./NUWebots && pip3 install -r ./requirements.txt && \
58
- ./b configure -- -DENABLE_CLANG_TIDY=OFF && ./b build
59
-
60
- RUN wget https://raw.githubusercontent.com/NUbots/NUWebots/main/webots-docker/webots-config.py && \
61
- wget https://raw.githubusercontent.com/NUbots/NUWebots/main/webots-docker/entrypoint.sh && \
62
- chmod +x entrypoint.sh
77
+ RUN git clone https://github.com/NUbots/NUWebots /NUWebots
78
+ RUN pip3 install -r /NUWebots/requirements.txt
79
+ RUN /NUWebots/b configure -- -DENABLE_CLANG_TIDY=OFF
80
+ RUN /NUWebots/b build
81
+
82
+ RUN wget https://raw.githubusercontent.com/NUbots/NUWebots/williamson/webots-docker/webots-docker/entrypoint.sh
83
+ RUN wget https://raw.githubusercontent.com/NUbots/NUWebots/williamson/webots-docker/webots-docker/webots-config.py
84
+ RUN chmod +x entrypoint.sh
63
85
64
86
# Configure robocup game.json file based on environment variables
65
87
ENTRYPOINT ["./entrypoint.sh" ]
0 commit comments