-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathDockerfile
37 lines (31 loc) · 1.12 KB
/
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
# use the official ROS 2 humble base image
ARG ROS_DISTRO=humble
FROM ros:${ROS_DISTRO} AS deps
# set the working directory and copy files
WORKDIR /root/ros2_ws
SHELL ["/bin/bash", "-c"]
COPY . /root/ros2_ws/src
# clone dependencies
RUN cd /root/ros2_ws/src && vcs import < dependencies.repos
# install dependencies
RUN source /opt/ros/${ROS_DISTRO}/setup.bash
RUN apt-get update \
&& apt-get -y --quiet --no-install-recommends install \
gcc \
git \
wget \
portaudio19-dev \
python3 \
python3-pip
RUN rosdep update && rosdep install --from-paths src --ignore-src -r -y
RUN pip3 install -r src/llama_ros/requirements.txt --use-deprecated=legacy-resolver
RUN pip3 install -r src/whisper_ros/requirements.txt --use-deprecated=legacy-resolver
RUN pip3 install -r src/piper_ros/requirements.txt --use-deprecated=legacy-resolver
# colcon the ws
FROM deps AS builder
ARG CMAKE_BUILD_TYPE=Release
RUN source /opt/ros/${ROS_DISTRO}/setup.bash && colcon build
# source the ROS 2 setup file
RUN echo "source /root/ros2_ws/install/setup.bash" >> ~/.bashrc
# run a default command, e.g., starting a bash shell
CMD ["bash"]