diff --git a/Dockerfile.theia b/Dockerfile.theia index 65d57f7..3f7989e 100644 --- a/Dockerfile.theia +++ b/Dockerfile.theia @@ -1,11 +1,20 @@ from theiaide/theia-python:latest + RUN apt-get update \ - && apt-get -y upgrade \ && apt-get -y install libgs-dev \ && rm -rf /var/lib/apt/lists/* +# Install docker for the container to enable access to a docker host if socket is mounted +RUN wget https://download.docker.com/linux/static/stable/x86_64/docker-20.10.2.tgz \ + && tar -xvf docker-20.10.2.tgz docker/docker && cp docker/docker /usr/bin/ + + +# Install Python requirements to support development COPY ./requirements.txt . -run pip3 install --upgrade pip && pip3 install -r requirements.txt && pip3 install pytest pylint bandit flake8 black pytest-django six pytest-mock -#COPY . /home/project -RUN wget https://download.docker.com/linux/static/stable/x86_64/docker-20.10.2.tgz && tar -xvf docker-20.10.2.tgz docker/docker && cp docker/docker /usr/bin/ +run pip3 install --upgrade pip \ + && pip3 install -r requirements.txt \ + && pip3 install pytest pylint bandit flake8 black pytest-django six pytest-mock + +COPY . /home/development + #ENTRYPOINT node /home/theia/src-gen/backend/main.js /home/project/ --hostname=0.0.0.0 \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..935e333 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,14 @@ +version: '2' +services: + nginx: + image: docker.triton2.fet.at/dev_nginx + ports: + - "5005:80" + theia: + image: docker.triton2.fet.at/dev_theia + volumes: + - /var/run/docker.sock:/var/run/docker.sock + - data_dev:/home +volumes: + data_dev: + driver: local