What is OctoPrint?
OctoPrint provides a snappy web interface for controlling consumer 3D printers. -https://github.com/OctoPrint/OctoPrint
Installation
- Log into the Linux device
- Run the following commands in terminal
# update software repositories
sudo apt update
# install available software updates
sudo apt upgrade -y
# install prerequisites
sudo apt install python3 python3-pip python3-dev python3-setuptools python3-venv git libyaml-dev build-essential libffi-dev libssl-dev -y
# create an octoprint directory
sudo mkdir /opt/OctoPrint
# set ownership of the directory
sudo chown $USER:$USER /opt/OctoPrint
# change directory
cd /opt/OctoPrint
# create a python virtual environment
python3 -m venv venv
# activate the virtual environment
source venv/bin/activate
# install wheel
pip install --upgrade pip wheel
# install octoprint
pip install octoprint
# test octoprint installation
/opt/OctoPrint/venv/bin/octoprint serve - Open a web browser and navigate to http://DNSorIP:5000
- Click Next on the Start screen
- Click Next on the Restore Backup screen
- Create an account my entering a Username and entering and confirming a password > Click Create Account
- Once the account is created, click Next
- Choose to Enable or Disable the Connectivity Check > Click Next
- Choose to Enable or Disable Anonymous Usage Tracking > Click Next
- Choose to Enable or Disable the Plugin Blacklist > Click Next
- Click Next on the Webcam Wizard screen
- Click Next on the Default Printer Profile screen
- Click Next on the Server Commands screen
- Acknowledge all the messages on the Finish screen > Click Finish
- Welcome to OctoPrint
Run OctoPrint as a Service (optional, but recommended)
- Back in the Terminal, press CTRL+C to kill the running OctoPrint process
- Continue with the following commands in terminal
# create octoprint service file
sudo nano /etc/systemd/system/octoprint.service - Paste the following into octoprint.service
[Unit]
Description=The snappy web interface for your 3D printer
After=network-online.target
Wants=network-online.target[Service]
Environment="LC_ALL=C.UTF-8"
Environment="LANG=C.UTF-8"
Type=exec
User=<% replace with your username %>
ExecStart=/opt/OctoPrint/venv/bin/octoprint serve[Install]
WantedBy=multi-user.target - Press CTRL+O, Enter, CTRL+X to write the changes
- Continue with the following commands
# reload systemd services
sudo systemctl daemon-reload
# start the octoprint service on boot and now
sudo systemctl enable octoprint --now - Back in the web browser, refresh the OctoPrint tab