launches automatically

This commit is contained in:
Matas Keras 2023-07-04 14:37:54 -04:00
parent 8e0f0880b8
commit 27026bf064
2 changed files with 8 additions and 3 deletions

View File

@ -384,7 +384,7 @@ RUN echo "arrow" | sudo -S apt install ros-melodic-tf2-geometry-msgs
#RUN rosdep update #RUN rosdep update
#RUN cd ~/catkin_ws && catkin config --extend /opt/ros/melodic #RUN cd ~/catkin_ws && catkin config --extend /opt/ros/melodic
#RUN source ~/catkin_ws/deve/setup.bash #RUN source ~/catkin_ws/deve/setup.bash
RUN cd ~/catkin_ws && catkin build #RUN cd ~/catkin_ws && catkin build
RUN bash ~/catkin_ws/src/oscillation_ctrl/px4_setup/ubuntu_sim_ros_melodic.sh RUN bash ~/catkin_ws/src/oscillation_ctrl/px4_setup/ubuntu_sim_ros_melodic.sh
#RUN git config --global --add safe.directory /home/arrow/Firmware #RUN git config --global --add safe.directory /home/arrow/Firmware
RUN cd ~/PX4-Autopilot && DONT_RUN=1 make px4_sitl_default gazebo RUN cd ~/PX4-Autopilot && DONT_RUN=1 make px4_sitl_default gazebo

View File

@ -1,7 +1,12 @@
services: services:
px4: px4:
build: Docker_PX4 build: Docker_PX4
command: bash command: bash -c "source /opt/ros/melodic/setup.bash &&
source /home/arrow/catkin_ws/devel/setup.bash &&
source home/arrow/PX4-Autopilot/Tools/simulation/gazebo-classic/setup_gazebo.bash home/arrow/PX4-Autopilot/ home/arrow/PX4-Autopilot//build/px4_sitl_default &&
export ROS_PACKAGE_PATH=/home/arrow/catkin_ws/src/oscillation_ctrl:/opt/ros/melodic/share:/home/arrow/PX4-Autopilot:/home/arrow/PX4-Autopilot/Tools/sitl_gazebo:/home/arrow/PX4-Autopilot:/home/arrow/PX4-Autopilot/Tools/simulation/gazebo-classic/sitl_gazebo-classic &&
roslaunch px4 multi_uav_mavros_sitl.launch"
tty: true tty: true
privileged: true privileged: true
volumes: volumes: