-
Notifications
You must be signed in to change notification settings - Fork 8
/
Dockerfile
26 lines (20 loc) · 964 Bytes
/
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
# This software is distributed under the terms of the GPL v3 License.
# Copyright (c) 2021-2024 Dmitry Ponomarev.
# Author: Dmitry Ponomarev <ponomarevda96@gmail.com>
ARG ROS_DISTRO=noetic
FROM ros:$ROS_DISTRO
LABEL description="UAV simulator"
SHELL ["/bin/bash", "-c"]
WORKDIR /catkin_ws/src/uav_hitl_simulator
# 1. Install requirements
COPY scripts/install.sh scripts/install.sh
RUN apt-get update && ./scripts/install.sh --yes && apt-get clean
# 2. Copy the source files
COPY . /catkin_ws/src/uav_hitl_simulator
# 3. Build ROS
RUN source /opt/ros/$ROS_DISTRO/setup.bash && cd /catkin_ws/ && git config --global http.sslverify false && catkin build
RUN echo source scripts/run_sim.sh ros >> ~/.bashrc
RUN ln -s /usr/bin/python3 /usr/bin/python
CMD echo "main process has been started" && \
source /opt/ros/$ROS_DISTRO/setup.bash && source /catkin_ws/devel/setup.bash && \
echo "container has been finished"