-
Notifications
You must be signed in to change notification settings - Fork 18
/
Dockerfile.indigo
60 lines (51 loc) · 1.82 KB
/
Dockerfile.indigo
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
FROM ros:indigo-robot
SHELL ["bash", "-c"]
ENV MY_DISTRO indigo
ENV WORKSPACE /catkin_ws
ARG RUN_TESTS=false
# prepare catkin and all euslisp packages
RUN apt-get -q -qq update \
&& apt-get -q -qq dist-upgrade -y \
&& apt-get -q -qq install -y \
ros-${MY_DISTRO}-catkin \
python-wstools python-catkin-tools \
bc net-tools iputils-ping
# create catkin workspace
RUN mkdir -p ${WORKSPACE}/src/aero-ros-pkg
WORKDIR ${WORKSPACE}
RUN wstool init ${WORKSPACE}/src
COPY . ${WORKSPACE}/src/aero-ros-pkg/
# catkin build
WORKDIR ${WORKSPACE}
RUN source /opt/ros/${MY_DISTRO}/setup.bash \
&& rosdep install -q -y -r --from-paths src --ignore-src \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/
RUN source /opt/ros/${MY_DISTRO}/setup.bash \
&& catkin config --init
RUN source /opt/ros/${MY_DISTRO}/setup.bash \
&& catkin build aero_description
WORKDIR ${WORKSPACE}/src/aero-ros-pkg/aero_description
RUN source ${WORKSPACE}/devel/setup.bash \
&& ./setup.sh typeF
WORKDIR ${WORKSPACE}
## build check
RUN source ${WORKSPACE}/devel/setup.bash \
&& catkin build aero_std
RUN source ${WORKSPACE}/devel/setup.bash \
&& catkin build aero_samples
RUN source ${WORKSPACE}/devel/setup.bash \
&& catkin build aero_gazebo
## test
RUN if [ "$RUN_TESTS" = "true" ]; then \
source ${WORKSPACE}/devel/setup.bash \
&& catkin run_tests --no-deps aero_ros_controller \
&& catkin_test_results ${WORKSPACE}/build/aero_ros_controller; fi
RUN if [ "$RUN_TESTS" = "true" ]; then \
source ${WORKSPACE}/devel/setup.bash \
&& catkin run_tests --no-deps aero_std \
&& catkin_test_results ${WORKSPACE}/build/aero_std; fi
RUN if [ "$RUN_TESTS" = "true" ]; then \
source ${WORKSPACE}/devel/setup.bash \
&& catkin run_tests --no-deps aero_samples \
&& catkin_test_results ${WORKSPACE}/build/aero_samples; fi