Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
docker_ros_tensorflow
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
bachelor_ws
docker_ros_tensorflow
Commits
36470cf6
Commit
36470cf6
authored
2 years ago
by
franzqueissner
Browse files
Options
Downloads
Patches
Plain Diff
working container yay
parent
327a6c5b
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.vscode/settings.json
+3
-0
3 additions, 0 deletions
.vscode/settings.json
Dockerfile
+71
-34
71 additions, 34 deletions
Dockerfile
start_docker.sh
+20
-0
20 additions, 0 deletions
start_docker.sh
with
94 additions
and
34 deletions
.vscode/settings.json
0 → 100644
+
3
−
0
View file @
36470cf6
{
"ros.distro"
:
"noetic"
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Dockerfile
+
71
−
34
View file @
36470cf6
FROM
tensorflow/tensorflow:latest-gpu
ENV
ROS_DISTRO=${ROS_DISTRO}
ENV
ROS_DISTRO=noetic
SHELL
["/bin/bash", "-c"]
# install essentials
RUN
apt update
&&
apt
install
-q
-y
\
build-essential git swig
sudo
libcppunit-dev curl wget
# python-future
# install ros
## setup sources.list
# INSTALLATION ROS
RUN
echo
"deb http://packages.ros.org/ros/ubuntu
`
lsb_release
-sc
`
main"
>
\
/etc/apt/sources.list.d/ros-latest.list
## setup key
RUN
curl
-s
https://raw.githubusercontent.com/ros/rosdistro/master/ros.asc |
sudo
apt-key add -
# install bootstrap tools
## downdload and install ------------------ takes long!!
RUN
apt update
&&
apt
install
-y
\
python3-rosdep
\
python3-rosinstall
\
python3-wstool
\
python3-rosinstall-generator
\
python3-vcstools
\
python3-catkin-tools
\
ros-
${
ROS_DISTRO
}
-desktop-full
\
&&
rm
-rf
/var/lib/apt/lists/
*
## source in bashrc
RUN
echo
"source /opt/ros/
${
ROS_DISTRO
}
/setup.bash"
>>
~/.bashrc
RUN
source
~/.bashrc
# INSTALLATION PYTHON PACKAGES
RUN
apt update
&&
apt
install
-y
\
python3-rosdep python3-rosinstall
\
python3-rosinstall-generator python3-wstool
RUN
rosdep init
\
&&
rosdep update
RUN
pip
install
--upgrade
pip
RUN
pip
install
--upgrade
numpy numpy-quaternion
==
2020.5.11.13.33.35 wstool
RUN
pip
install
future panda-robot pynput numba scipy gym tensorflow-probability
RUN
apt-get update
&&
apt-get upgrade
-y
# INSTALLATION ROS PACKAGES
RUN
apt update
&&
apt
install
-y
\
ros-noetic-desktop-full
\
&&
rm
-rf
/var/lib/apt/lists/
*
ros-
${
ROS_DISTRO
}
-libfranka
ros-
${
ROS_DISTRO
}
-franka-ros
\
ros-
${
ROS_DISTRO
}
-gazebo-ros-control
\
ros-
${
ROS_DISTRO
}
-rospy-message-converter
\
ros-
${
ROS_DISTRO
}
-effort-controllers
\
ros-
${
ROS_DISTRO
}
-joint-state-controller
\
python3-catkin-tools
\
ros-
${
ROS_DISTRO
}
-ros-control
\
ros-
${
ROS_DISTRO
}
-ros-controllers
\
gazebo11
\
libgazebo11-dev
\
ros-
${
ROS_DISTRO
}
-combined-robot-hw
# MAKE + SOURCE CATKIN WORKSPACE + ROS DEP INIT
RUN
mkdir
-p
home/panda_ws/src
WORKDIR
"/home/panda_ws"
RUN
/bin/bash
-c
"source /opt/ros/
${
ROS_DISTRO
}
/setup.bash && catkin build && source devel/setup.bash"
RUN
/bin/bash
-c
"source /opt/ros/
${
ROS_DISTRO
}
/setup.bash && rosdep init && rosdep update && rosdep fix-permissions && rosdep update"
## SET UP SSH KEY FOR GIT
ARG
ssh_prv_key
ARG
ssh_pub_key
# authorize SSH Host
RUN
mkdir
-p
/root/.ssh
&&
\
chmod
700 /root/.ssh
&&
\
ssh-keyscan gitlab.bht-berlin.de
>
/root/.ssh/known_hosts
# add the keys and set permissions
RUN
echo
"
$ssh_prv_key
"
>
/root/.ssh/id_rsa
&&
\
echo
"
$ssh_pub_key
"
>
/root/.ssh/id_rsa.pub
&&
\
chmod
600 /root/.ssh/id_rsa
&&
\
chmod
600 /root/.ssh/id_rsa.pub
arg
adfsasdd
## CLONE ROS PACKAGES
RUN
cd
src
&&
git clone git@gitlab.bht-berlin.de:bachelor_ws/panda_control.git
RUN
cd
src
&&
git clone git@gitlab.bht-berlin.de:bachelor_ws/panda_openai.git
RUN
cd
src
&&
git clone git@gitlab.bht-berlin.de:bachelor_ws/panda_simulator.git
RUN
cd
src
&&
git clone https://bitbucket.org/theconstructcore/theconstruct_msgs.git
# next clones are in build_ws.sh
# RUN cd src && git clone git@gitlab.bht-berlin.de:bachelor_ws/franka_panda_description.git
# RUN cd src && git clone https://github.com/JustaGist/franka_ros_interface --branch v0.7.1-dev
# RUN cd src && git clone https://github.com/orocos/orocos_kinematics_dynamics
# script which ros depend and builds
RUN
cd
src/panda_simulator
&&
./build_ws.sh
# RUN sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
# RUN curl -s https://raw.githubusercontent.com/ros/rosdistro/master/ros.asc | sudo apt-key add -
# RUN apt-get install ros-noetic-desktop-full
# RUN echo "source /opt/ros/noetic/setup.bash" >> ~/.bashrc
# RUN source ~/.bashrc
#
## install ros packages
#RUN apt-get update && apt-get install -y \
# ros-$ROS_DISTRO-libfranka ros-$ROS_DISTRO-franka-ros \
# python-catkin-tools ros-$ROS_DISTRO-gazebo-ros-control \
# ros-${ROS_DISTRO}-rospy-message-converter ros-${ROS_DISTRO}-effort-controllers \
# ros-${ROS_DISTRO}-joint-state-controller python-pip
#
## install python packages
#RUN pip install --upgrade pip
#RUN pip install --upgrade numpy numpy-quaternion==2020.5.11.13.33.35
#RUN apt-get update && apt-get upgrade -y
## run simulation through script
COPY
start_docker.sh start_docker.sh
CMD
./start_docker.sh
This diff is collapsed.
Click to expand it.
start_docker.sh
0 → 100755
+
20
−
0
View file @
36470cf6
#!/bin/bash
# Start the primary process and put it in the background
source
devel/setup.bash
roslaunch panda_control panda_world.launch &
sleep
5
# Start the helper process
rosrun panda_control panda_control.py &
sleep
5
rosrun panda_openai agent_pg.py
# the my_helper_process might need to know how to wait on the
# primary process to start before it does its work and returns
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment