So, I'm trying to run docker inside Dockerfile ("the best idea ever") using command sudo docker service start
but it's always responds with
#9 0.142 mkdir: cannot create directory ‘cpuset’: Read-only file system
------
Dockerfile looks like this.
FROM jenkins/jenkins:lts
USER root
RUN apt-get update && apt-get upgrade -y
RUN apt-get update && \
apt-get -y install apt-transport-https \
ca-certificates \
curl \
gnupg2 \
software-properties-common && \
apt-get update && \
apt-get -y install docker.io && \
apt-get -y install sudo
RUN curl -fsSL https://download.docker.com/linux/debian/gpg | apt-key add -
RUN add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/debian \
$(lsb_release -cs) \
stable"
VOLUME /var/run/docker.sock
RUN sudo service docker start ///////1111111\\\\\\\\ The Error goes there.....
RUN adduser jenkins sudo
RUN echo “jenkins ALL=NOPASSWD: ALL” >> /etc/sudoers
RUN usermod -aG docker jenkins
RUN chown root:jenkins /var/run/docker.sock
USER jenkins
From the Error Response, Seems like I need to enable Write Mode
,there are many solutions/suggestions for that, but most of them unfortunately does not work....
Can it be the problem related to Image?
Would really appreciate any suggestions/tips, (but more likely the solution :))