octoprint/tasks/main.yaml
author Luke Hoersten <luke@hoersten.org>
Sun, 06 Nov 2022 23:10:04 -0600
changeset 203 4be395f0d127
parent 193 fd46c0e68c2c
child 238 bdbc88cb5078
permissions -rw-r--r--
Reduced number of open connections for dendrite due to startup error.

---

- name: add octoprint user
  become: yes
  user: name="octoprint" groups="{{octoprint_groups}}" home="/opt/octoprint" system="yes"

- name: pip install octoprint
  become: yes
  pip: name="octoprint" executable="pip3"
  notify: restart octoprint

- name: install octoprint systemd service
  become: yes
  copy:
    src: "octoprint.service"
    dest: "/lib/systemd/system/octoprint.service"
  notify: restart octoprint

- name: ensure octoprint service is started
  become: yes
  systemd: name="octoprint.service" enabled="yes"