{"id":18756510,"url":"https://github.com/octoprint/octoprint-docker","last_synced_at":"2025-04-14T08:16:31.909Z","repository":{"id":37211834,"uuid":"79459722","full_name":"OctoPrint/octoprint-docker","owner":"OctoPrint","description":"The dockerized snappy web interface for your 3D printer! ","archived":false,"fork":false,"pushed_at":"2025-02-18T17:29:58.000Z","size":282,"stargazers_count":504,"open_issues_count":33,"forks_count":227,"subscribers_count":18,"default_branch":"master","last_synced_at":"2025-04-14T08:16:26.857Z","etag":null,"topics":["3d-printing","docker","octoprint"],"latest_commit_sha":null,"homepage":"","language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/OctoPrint.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-01-19T14:11:30.000Z","updated_at":"2025-04-12T20:40:21.000Z","dependencies_parsed_at":"2024-11-07T17:53:00.506Z","dependency_job_id":null,"html_url":"https://github.com/OctoPrint/octoprint-docker","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctoPrint%2Foctoprint-docker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctoPrint%2Foctoprint-docker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctoPrint%2Foctoprint-docker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctoPrint%2Foctoprint-docker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OctoPrint","download_url":"https://codeload.github.com/OctoPrint/octoprint-docker/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248844000,"owners_count":21170499,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["3d-printing","docker","octoprint"],"created_at":"2024-11-07T17:36:54.341Z","updated_at":"2025-04-14T08:16:31.873Z","avatar_url":"https://github.com/OctoPrint.png","language":"Dockerfile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# OctoPrint-docker [![Chat](https://img.shields.io/badge/chat-on%20discord-7289da.svg)](https://discord.octoprint.org)\n\nThis is the primary image of `octoprint/octoprint`. It is designed to work similarly, and support the same out of the box features as the octopi raspberry-pi machine image, using docker.\n\nThe `octoprint/octoprint` image uses semantic versioning, but the tags for `octoprint/octoprint` follow the version of octoprint contained in the image. As a result we recommend you always check the [CHANGELOG](CHANGELOG.md) or [Releases](https://github.com/OctoPrint/octoprint-docker/releases) before pulling an image, _even if you are pulling the same tag_.\n\nYou can subscribe to be notified of releases as well, by selecting the Watch button in the upper right corner, choosing \"Custom\", and checking \"Releases\".\n\nIn addition, we know that OctoPrint is not the best suited type of application for containerization, but we're working hard to make it as compatible as possible. Please check out our [Roadmap](https://github.com/OctoPrint/octoprint-docker/projects/4), or join the discussion in the `#dev-docker` or `#support-docker` channels on the official OctoPrint Discord [discord.octoprint.org](https://discord.octoprint.org).\n\n**Tags and platforms**\n\nAll images for the `octoprint/octoprint` image are multi-arch images, and we publish for `arm64`, `arm/v7`, and `amd64` using the below tags:\n\n- `latest` - will always follow the latest _stable_ release\n- `edge` - will always follow the latest release _including prereleases_.\n- `canary` - follows the [OctoPrint/Octoprint@maintenance](https://github.com/OctoPrint/OctoPrint/tree/maintenance) branch\n- `bleeding`- follows the [OctoPrint/Octoprint@devel](https://github.com/OctoPrint/OctoPrint/tree/devel) branch\n- `X`,`X.Y`,`X.Y.Z`,`X.Y.Z-rc` - these tags will follow the latest build that matches the tag\n- `minimal` - This is built whenever `latest` is built, but uses the [minimal image](docs/using_the_minimal_image.md)\n- `latest|edge|canary|bleeding|X.Y.Z-minimal` - a minimal version of each of the tags described above, published under the same condition but from the [minimal image](docs/using_the_minimal_image.md)\n\n**Table of Contents**\n\n- [OctoPrint-docker ](#octoprint-docker-)\n  - [Usage](#usage)\n    - [Configuration](#configuration)\n      - [Enabling Webcam Support with Docker](#enabling-webcam-support-with-docker)\n      - [Container Environment Variables](#container-environment-variables)\n      - [Restarting OctoPrint](#restarting-octoprint)\n      - [Editing Config files manually](#editing-config-files-manually)\n  - [Without docker-compose](#without-docker-compose)\n  - [Extended Documentation](#extended-documentation)\n  - [Contributions Welcome](#contributions-welcome)\n\n## Usage\n\nWe recommend you use docker-compose to run octoprint via docker, and have included a recommended [docker-compose.yml](docker-compose.yml) file for your convenience.\n\nSave the contents of this file on your machine as `docker-compose.yml`, and then run `docker-compose up -d`.\n\nOpen octoprint at `http://\u003coctoprint_ip_or_url`\n\n### Configuration\n\n#### Enabling Webcam Support with Docker\n\nIn order to use the webcam, you'll need to make sure the webcam service is enabled.\nThis is done by setting the environment variable `ENABLE_MJPG_STREAMER=true` in your`docker run` command, or in the `docker-compose.yml` file.\n\nYou'll also need to add `--device /dev/video0:/dev/video0` to your `docker run`, or ensure it's listed in the `devices` array in your `docker-compose.yml`.\n\nIf you map a video device _other_ than `/dev/video0`, you will additionally need to set an environment variable for `CAMERA_DEV` to match the mapped device mapping.\n\nMake sure you use the following internal configuration (Settings » Webcam \u0026 Timelapse):\n\n- Stream URL: `/webcam/?action=stream`\n- Snapshot URL: `http://localhost:8080/?action=snapshot`\n- Path to FFMPEG: `/usr/bin/ffmpeg`\n\nURLs for reaching the camera from outside the container are:\n\n- Stream: `http://dockerIP:dockerport/webcam/?action=stream`\n- Snapshot: `http://dockerIP:dockerport/webcam/?action=snapshot`\n\nSee [container Environment Variables](#container-environment-variables) for a full list of webcam configuration options configured with docker.\n\n#### Container Environment Variables\n\nThere are configuration values that you pass using container `--environment` options.\nListed below are the options and their defaults. These are implicit in example [docker-compose.yml](docker-compose.yml), and if you wish to change them, refer to the docker-compose docs on setting environment variables.\n\n| variable               | default         | description                                                                                                                                                                                                                                             |\n| ---------------------- | --------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `CAMERA_DEV`           | `/dev/video0`   | The camera device(s) inside the container. (See [Camera Devices](#camera-devices) note below)                                                                                                                                                           |\n| `MJPG_STREAMER_INPUT`  | `-n -r 640x480` | params for mjpg-streamer                                                                                                                                                                                                                                |\n| `ENABLE_MJPG_STREAMER` | `false`         | enable or disable mjpg-streamer                                                                                                                                                                                                                         |\n| `AUTOMIGRATE`          | `false`         | Will attempt to detect and migrate filesystems structures from previous versions of this image to be compatible with the latest release version. recommend you backup before trying this as this is a new feature that has been difficult to test fully |\n\n##### Camera Devices\n\nYou will still need to declare the `device` mapping in your docker-compose file or docker command, even if you explicitly declare the `CAMERA_DEV`.\nThe value of `CAMERA_DEV` is used in starting the mjpg-streamer service, whereas the `devices` mapping is used by docker to make sure the container has access to the device.\n\nFor example, if you change the `CAMERA_DEV` to be `/dev/video1`, you would also need to map `/dev/video1:/dev/video1` in your container.\n\n###### Multiple Cameras\n\nYou may optionally provide a comma separated list of devices such as `/dev/video0,/dev/video1` to map multiple devices.\nRemember to map them all to the container in the `devices` array.\n\nMJPG Streamer will be started for each device, and the stream URL will be `/webcam/\u003cdevice_name\u003e/?action=stream` where `\u003cdevice_name\u003e` is the name of the device, e.g. `video0`.\n\nWithin the container the MJPG port will start at 8080 and increment for each device, e.g. 8080, 8081, 8082, etc.\n\n#### Restarting OctoPrint\n\nWhilst the container should be pre-configured to allow for OctoPrint to be restarted within the container, there are still some edge cases where this pre-configuration does not take effect. If the option to restart OctopPrint is not present in the user interface, ensure the following command is present in the `Restart OctoPrint` field under the Server section of the OctoPrint Settings.\n\n```shell\ns6-svc -r /var/run/s6/services/octoprint\n```\n\n#### Editing Config files manually\n\nThis docker-compose file also contains a container based instance of [vscode][], accessible via your browser at the same url as your octoprint instance, allowing you to edit configuration files without needing to login to your octoprint host.\n\nTo make use of this editor, just uncomment the indicated lines in your [docker-compose.yml](docker-compose.yml#L20-L32) then run the following commands:\n\n```shell\ndocker-compose up -d config-editor\n```\n\nNow go to `http://\u003coctoprint_ip_or_url\u003e:8443/?folder=/octoprint` in your browser to edit your octoprint files!\nUse the 'explorer' (accessible by clicking the hamburger menu icon) to explore folder and files to load into the editor workspace.\n\nAll configuration files are in the `octoprint` folder, and the active configuration will be accessible at `/octoprint/octoprint/config.yaml`\n\nWhen you're done, we recommend you stop and remove this service/container:\n\n```shell\ndocker-compose stop config-editor \u0026\u0026 docker-compose rm config-editor\n```\n\nFor full documentation about the config editor, see the docs for the product at [github.com/cdr/code-server][code-server].\n\n## Without docker-compose\n\nIf you prefer to run without docker-compose, first create an `octoprint` docker volume on the host, and then start your container:\n\n```shell\ndocker volume create octoprint\ndocker run -d -v octoprint:/octoprint --device /dev/ttyACM0:/dev/ttyACM0 --device /dev/video0:/dev/video0 -e ENABLE_MJPG_STREAMER=true -p 80:80 --name octoprint octoprint/octoprint\n```\n\n[code-server]: https://github.com/cdr/code-server\n[vscode]: https://code.visualstudio.com\n\n## Extended Documentation\n\nWe are in the process of creating more extensive documentation for using the octoprint/octprint image. Check out the [docs](docs/README.md)\n\nIf you would like to build the docker image yourself, please read [building-an-octoprint-image](docs/README.md#building-your-own-octoprint-image)\n\n## Contributions Welcome\n\nWe are welcoming contributions, and looking to add maintainers to the team. View [CONTRIBUTING.md](CONTRIBUTING.md) for more info!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foctoprint%2Foctoprint-docker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foctoprint%2Foctoprint-docker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foctoprint%2Foctoprint-docker/lists"}