Skip to content

Removed instructions on using and installing Docker on README #2415

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 7, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 2 additions & 50 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,56 +100,8 @@ Documentation is in progress at [ReadTheDocs](https://docs.manim.community/).

## Docker

The community also maintains a docker image (`manimcommunity/manim`), which can be found [on DockerHub](https://hub.docker.com/r/manimcommunity/manim). The following tags are supported:

- `latest` -- the most recent version corresponding to [the main branch](https://github.com/ManimCommunity/manim)
- `stable` -- the latest released version (according to [the releases page](https://github.com/ManimCommunity/manim/releases))
- `vX.Y.Z` -- any particular released version (according to [the releases page](https://github.com/ManimCommunity/manim/releases))

### Instructions for running the docker image

#### Quick Example
To render a scene `CircleToSquare` in a file `test_scenes.py` contained in your current working directory while preserving your user and group ID, use

```sh
docker run --rm -it --user="$(id -u):$(id -g)" -v "$(pwd)":/manim manimcommunity/manim manim test_scenes.py CircleToSquare -qm
```

#### Running the image in the background

Instead of using the "throwaway container" approach sketched above, you can also create a named container that you can also modify to your liking. First, run

```sh
docker run -it --name my-manim-container -v "$(pwd):/manim" manimcommunity/manim /bin/bash
```

to obtain an interactive shell inside your container allowing you to, e.g., install further dependencies (like texlive packages using `tlmgr`). Exit the container as soon as you are satisfied. Then, before using it, start the container by running

```sh
docker start my-manim-container
```

Then, to render a scene `CircleToSquare` in a file `test_scenes.py`, call

```sh
docker exec -it --user="$(id -u):$(id -g)" my-manim-container manim test.py CircleToSquare -qm
```

#### Jupyterlab

Another alternative is to use the docker image to spin up a local webserver running
JupyterLab in whose Python kernel manim is installed and can be accessed via the `%%manim` cell magic.
To use JupyterLab, run

```sh
docker run -it -p 8888:8888 manimcommunity/manim jupyter lab --ip=0.0.0.0
```

and then follow the instructions in the terminal.

#### Important notes

When executing `manim` within a Docker container, several command line flags (in particular `-p` (preview file) and `-f` (show output file in the file browser)) are not supported.
The community also maintains a docker image (`manimcommunity/manim`), which can be found [on DockerHub](https://hub.docker.com/r/manimcommunity/manim).
Instructions on how to install and use it can be found in our [documentation](https://docs.manim.community/en/stable/installation/docker.html).

## Help with Manim

Expand Down