Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker #124

Merged
merged 8 commits into from
Jan 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[submodule "pycram/src/macropy"]
path = src/macropy
url = git@github.com:Tigul/macropy.git
[submodule "src/neem_interface_python"]
path = src/neem_interface_python
url = https://github.com/Tigul/neem_interface_python
[submodule "src/macropy"]
path = src/macropy
url = https://github.com/Tigul/macropy.git
29 changes: 29 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@

ARG FROM_IMAGE=ros:noetic-ros-core-focal
ARG OVERLAY_WS=/opt/ros/overlay_ws

FROM $FROM_IMAGE as builder
ARG OVERLAY_WS=/opt/ros/overlay_ws
WORKDIR $OVERLAY_WS/src

RUN sudo apt-get update && apt-get install python3-pip python3-vcstool git -y
RUN vcs import --input https://raw.githubusercontent.com/cram2/pycram/dev/pycram-https.rosinstall --recursive --skip-existing $OVERLAY_WS/src
RUN sudo apt-get update && apt-get install python3-pip -y && pip3 install pip --upgrade
RUN pip3 install --no-cache-dir -r $OVERLAY_WS/src/pycram/requirements.txt

RUN pip3 install rosdep && rosdep init
RUN rosdep update && rosdep install --from-paths $OVERLAY_WS/src --ignore-src -r -y
RUN sudo apt-get install jupyter -y

RUN . /opt/ros/noetic/setup.sh && cd $OVERLAY_WS && catkin_make
RUN echo "source $OVERLAY_WS/devel/setup.bash" >> ~/.bashrc
RUN rm -rf $OVERLAY_WS/src/pycram

COPY . $OVERLAY_WS/src/pycram
RUN pip3 install -r $OVERLAY_WS/src/pycram/requirements.txt
COPY docker/entrypoint.sh /
ENTRYPOINT ["bash", "/entrypoint.sh"]

# launch ros package
#CMD ["roslaunch", "pycram", "ik_and_description.launch", "&"]
#CMD ["jupyter", "notebook", "--ip", "0.0.0.0", "--allow-root", "/opt/ros/overlay_ws/src/pycram/examples/"]
7 changes: 7 additions & 0 deletions docker/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash

set -e

source /opt/ros/overlay_ws/devel/setup.bash

exec "$@"
25 changes: 25 additions & 0 deletions pycram-https.rosinstall
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
repositories:
iai_maps:
type: git
url: https://github.com/code-iai/iai_maps.git
version: master
iai_robots:
type: git
url: https://github.com/code-iai/iai_robots.git
version: master
pycram:
type: git
url: https://github.com/cram2/pycram.git
version: dev
pr2_common:
type: git
url: https://@github.com/PR2/pr2_common.git
version: b34703bcca2b07cadbc3777d3c504c232a0c0c28
kdl_ik_services:
type: git
url: https://github.com/cram2/kdl_ik_service.git
version: master
pr2_kinematics:
type: git
url: https://github.com/PR2/pr2_kinematics.git
version: kinetic-devel
2 changes: 1 addition & 1 deletion pycram.rosinstall
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ repositories:
kdl_ik_services:
type: git
url: git@github.com:cram2/kdl_ik_service.git
verison: master
version: master
pr2_kinematics:
type: git
url: git@github.com:PR2/pr2_kinematics.git
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ rospkg~=1.4.0
roslibpy~=1.2.1
# rospy~=1.14.11
pathlib~=1.0.1
numpy~=1.22.2
numpy==1.24.3
pytransform3d~=1.9.1
# tf~=1.12.1
# actionlib~=1.12.1
Expand Down
2 changes: 1 addition & 1 deletion src/neem_interface_python
Loading