Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Document how to use Python & Jupyter #4333

Closed
Labels
docsDocumentation related
Milestone
@AyaanZaveri

Description

  1. First, add these lines to your Dockerfile to install Miniconda/Anaconda:
RUN curl -sfLO https://repo.anaconda.com/miniconda/Miniconda3-py39_4.9.2-Linux-x86_64.sh \
 && /bin/bash Miniconda3-py39_4.9.2-Linux-x86_64.sh -b -p /root/miniconda \
 && PATH="/root/miniconda/bin:$PATH" \
 && conda install -c anaconda jupyter
  1. Then, install the Python Extension and make sure it comes with the Jupyter Extension or you can add this line to your Dockerfile:
RUN code-server --install-extension ms-python.python
RUN code-server --install-extension ms-toolsai.jupyter
  1. Next, in Code-Server create a file with the extension .ipynb like main.ipynb and set your Python Interpreter as the location of miniconda (~/miniconda/bin/python).
  2. Finally, you can add your python code to the file and it should work perfectly.
    Screen Shot 2021年10月09日 at 6 35 56 PM
    Screen Shot 2021年10月09日 at 6 36 52 PM

If this doesn't work use the Dockerfile from #3199 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation related

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      AltStyle によって変換されたページ (->オリジナル) /