Closed demathelin closed 6 months ago
Hey, thanks for the report.
It seems the group id 1000
already exists inside the image theta_container
by the name ubuntu
according to this line:
-> inside_gname_bygid:ubuntu, outside container: gdemathelin
Could it be that you're creating it in the image? (maybe in the Dockerfile?)
If so, I'm not sure what's the best solution (because the group would need to be deleted inside the container and, though it might work in this case, I doubt it's a good choice in the long run, for instance, it might happen to other system-level groups). Do you have any thoughts?
edit: I assume it is created inside the image because I haven't encountered it in the default ubuntu images, but I might be wrong. Can you share the Dockerfile and/or the base image used?
Here is my Dockerfile:
FROM ubuntu:23.10 as base
USER root
ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1
ENV DEBIAN_FRONTEND noninteractive
# install python3.12
RUN apt update &&\
apt upgrade -y && \
apt install -y --no-install-recommends curl gcc g++ gnupg unixodbc-dev openssl git &&\
apt install -y software-properties-common ca-certificates &&\
apt install -y build-essential zlib1g-dev libncurses5-dev libgdbm-dev libssl-dev libreadline-dev libffi-dev wget libbz2-dev libsqlite3-dev && \
update-ca-certificates && \
rm -rf /var/lib/apt/lists/*
RUN mkdir /python && cd /python && \
wget https://www.python.org/ftp/python/3.12.2/Python-3.12.2.tgz && \
tar -zxvf Python-3.12.2.tgz && \
cd Python-3.12.2 && \
ls -lhR && \
./configure CFLAGS="-fPIC" --enable-optimizations && \
make install && \
rm -rf /python
RUN apt update
RUN apt install -y build-essential g++ autotools-dev libicu-dev libbz2-dev
RUN apt install -y git clang libclang-dev
RUN apt install -y cmake libeigen3-dev doxygen
RUN apt install -y curl libcurl4-openssl-dev libzstd-dev
RUN python3 -m ensurepip --upgrade
RUN pip3 install numpy wheel pyplusplus pygccxml==2.2.1 scipy setuptools
WORKDIR ./../..
RUN apt update
RUN apt install -y libzmq3-dev
RUN git clone https://github.com/meshcat-dev/meshcat-python.git meshcat
WORKDIR ./meshcat
RUN git checkout 785bc9d5ba6f8a8bb79ee8b25f523805946c1fbd && \
git submodule update --init --recursive
RUN python3 setup.py install
WORKDIR ./..
RUN pip3 install qpsolvers[clarabel]
RUN git clone https://github.com/JuJankowski/vp-sto.git vpsto
WORKDIR ./vpsto
RUN pip3 install .
WORKDIR ./..
RUN apt install -y libglfw3-dev
RUN pip3 install git+https://github.com/quadprog/quadprog.git@refs/pull/43/head
WORKDIR /
RUN pip3 install git+https://github.com/google-deepmind/dm_control.git
RUN mkdir /boost && cd /boost && \
wget -O boost_1_77_0.tar.bz2 https://sourceforge.net/projects/boost/files/boost/1.77.0/boost_1_77_0.tar.bz2/download &&\
tar xvfo boost_1_77_0.tar.bz2
RUN ln -s /usr/local/bin/python3 /usr/local/bin/python
WORKDIR ./boost/boost_1_77_0
RUN ./bootstrap.sh --prefix=/usr/local --with-python=python3 --with-libraries=filesystem,math,program_options,python,serialization,system &&\
./b2 &&\
./b2 install
WORKDIR /
RUN git clone https://github.com/CastXML/CastXML.git castxml
WORKDIR ./castxml
RUN git checkout 1a460924d456d9983082d615e0df5f797fdeb635
RUN mkdir -p build
WORKDIR ./build
RUN cmake ..
RUN make -j16
RUN make install
WORKDIR ../..
RUN pip3 install pygad
# RUN pip3 install -U "jax[cuda11_pip]" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html
RUN pip3 install mujoco-mjx
RUN pip3 install flake8
RUN apt install -y libxinerama-dev libxcursor-dev libxi-dev
WORKDIR /home/ubuntu
RUN git clone https://github.com/google-deepmind/mujoco.git mujoco && \
cd mujoco && \
mkdir build && \
cd build && \
cmake .. && \
make -j16
RUN pip3 install qpmpc pygame
WORKDIR /
RUN git clone https://github.com/hashb/toppra.git toppra_lib
WORKDIR ./toppra_lib
RUN git checkout c28fd7cbc5039e9b1c1f1482f66e94a70465dda5
RUN pip3 install -r requirements3.txt
RUN pip3 install -e .
WORKDIR /
RUN apt -y install qtbase5-dev libqt5svg5-dev libqt5websockets5-dev \
libqt5opengl5-dev libqt5x11extras5-dev libprotoc-dev libzmq3-dev \
liblz4-dev libzstd-dev
WORKDIR /toppra_lib/toppra/constraint
RUN for i in $(ls -d *.py); do sed -i 's/"""/r"""/g' $i ; done
RUN for i in $(ls -d *.py); do sed -i 's/rr"""/r"""/g' $i ; done
WORKDIR /toppra_lib/toppra
RUN for i in $(ls -d *.py); do sed -i 's/"""/r"""/g' $i ; done
RUN for i in $(ls -d *.py); do sed -i 's/rr"""/r"""/g' $i ; done
WORKDIR /toppra_lib/toppra/solverwrapper
RUN for i in $(ls -d *.py); do sed -i 's/"""/r"""/g' $i ; done
RUN for i in $(ls -d *.py); do sed -i 's/rr"""/r"""/g' $i ; done
RUN pip3 install pin
RUN apt install -y octave
RUN pip3 install oct2py
WORKDIR /
RUN git clone https://github.com/demathelin/odio_urdf.git odio_urdf
WORKDIR ./odio_urdf
RUN git pull
RUN pip3 install .
WORKDIR /
RUN pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu
Thanks for pointing this out.
It seems that since 23.04
, ubuntu images now have a default user called ubuntu
with uid and gid 1000:
$ docker run --rm -it ubuntu:23.04 getent group | grep 1000
ubuntu:x:1000: # group inside image
$ docker run --rm -it ubuntu:22.10 getent group | grep 1000
# returns nothing
If you used 22.10 or below as a base, dogi would work as intended. I'm not sure why nor if it's intended but I'll guess I'll find a way to work around it in the mean time.
@demathelin should be fixed in latest release version (or update with dogi update
:wink: )
If not, feel free to open it gain.
Yes, it works now ! Thank you !
Hello, First of all, thank you for your work ! I am still using your package and it works fine for my Ubuntu 22.04. I have this tiny bug: I am not able to open a container without being root (I can only use dogi with the cmd --no-user). Here is the log:
Thanks again for your work.