This repository has been archived by the owner on Oct 5, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 345
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
python: update images to use vscode extensions
Fixes #74 - updates the `theia-python:latest` image to use builtin and vscode extensions. - updates the `theia-python:next` image to use builtin and vscode extensions. - updates the image to support both python 2 and 3. - includes the necessary tools for python development. Signed-off-by: vince-fugnitto <vincent.fugnitto@ericsson.com>
- Loading branch information
1 parent
9139e67
commit b143288
Showing
3 changed files
with
162 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,30 @@ | ||
ARG NODE_VERSION=10 | ||
FROM node:${NODE_VERSION}-stretch | ||
FROM node:${NODE_VERSION} | ||
|
||
RUN apt-get update \ | ||
&& apt-get install -y python python-dev python-pip \ | ||
&& apt-get clean && rm -rf /var/cache/apt/* && rm -rf /var/lib/apt/lists/* && rm -rf /tmp/* | ||
&& apt-get install -y python-dev python-pip \ | ||
&& apt-get install -y python3-dev python3-pip \ | ||
&& apt-get install -y yarn \ | ||
&& apt-get clean \ | ||
&& rm -rf /var/cache/apt/* \ | ||
&& rm -rf /var/lib/apt/lists/* \ | ||
&& rm -rf /tmp/* | ||
|
||
RUN pip install \ | ||
python-language-server \ | ||
flake8 \ | ||
autopep8 | ||
RUN adduser --disabled-password --gecos '' theia | ||
RUN chmod g+rw /home && \ | ||
mkdir -p /home/project && \ | ||
chown -R theia:theia /home/theia && \ | ||
chown -R theia:theia /home/project; | ||
WORKDIR /home/theia | ||
USER theia | ||
|
||
ARG version=latest | ||
|
||
WORKDIR /home/theia | ||
ADD $version.package.json ./package.json | ||
ARG GITHUB_TOKEN | ||
RUN yarn --cache-folder ./ycache && rm -rf ./ycache | ||
RUN yarn theia build | ||
RUN yarn --cache-folder ./ycache && rm -rf ./ycache && \ | ||
yarn theia build ; \ | ||
yarn theia download:plugins | ||
EXPOSE 3000 | ||
ENV SHELL /bin/bash | ||
ENV SHELL=/bin/bash \ | ||
THEIA_DEFAULT_PLUGINS=local-dir:/home/theia/plugins | ||
ENTRYPOINT [ "yarn", "theia", "start", "/home/project", "--hostname=0.0.0.0" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.