Dateien hochladen nach „“
This commit is contained in:
parent
f4380fd8f2
commit
92213ce289
26
Dockerfile
Normal file
26
Dockerfile
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
# Use ROS 2 Humble Hawksbill base image
|
||||||
|
FROM osrf/ros:humble-desktop-full
|
||||||
|
|
||||||
|
# Update and install dependencies
|
||||||
|
RUN apt-get update && apt-get install -y \
|
||||||
|
python3-colcon-common-extensions \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
COPY requirements.txt ./
|
||||||
|
RUN pip install --no-cache-dir -r requirements.txt
|
||||||
|
|
||||||
|
# Create a workspace
|
||||||
|
WORKDIR /ros2_ws
|
||||||
|
|
||||||
|
# Copy your ROS 2 package into the workspace
|
||||||
|
COPY ./src /ros2_ws/src
|
||||||
|
|
||||||
|
# Build your package
|
||||||
|
RUN . /opt/ros/humble/setup.sh && \
|
||||||
|
colcon build
|
||||||
|
|
||||||
|
RUN echo "source /opt/ros/humble/setup.bash" >> ~/.bashrc
|
||||||
|
|
||||||
|
|
||||||
|
# Source the workspace
|
||||||
|
CMD ["/bin/bash"]
|
14
docker-compose.yaml
Normal file
14
docker-compose.yaml
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
version: '3.8'
|
||||||
|
services:
|
||||||
|
ros2:
|
||||||
|
build: ..
|
||||||
|
volumes:
|
||||||
|
- ./src:/ros2_ws/src
|
||||||
|
networks:
|
||||||
|
- ros_network
|
||||||
|
tty: true
|
||||||
|
stdin_open: true
|
||||||
|
|
||||||
|
networks:
|
||||||
|
ros_network:
|
||||||
|
driver: bridge
|
1
requirements.txt
Normal file
1
requirements.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
numpy==1.26.4
|
Loading…
Reference in New Issue
Block a user