Add haproxy to octoprint
This commit is contained in:
parent
05378fc81c
commit
3a640f10d8
13
roles/octoprint/files/etc/haproxy/haproxy.cfg
Normal file
13
roles/octoprint/files/etc/haproxy/haproxy.cfg
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
global
|
||||||
|
daemon
|
||||||
|
maxconn 256
|
||||||
|
|
||||||
|
defaults
|
||||||
|
mode http
|
||||||
|
timeout connect 5000ms
|
||||||
|
timeout client 50000ms
|
||||||
|
timeout server 50000ms
|
||||||
|
|
||||||
|
listen http-in
|
||||||
|
bind *:80
|
||||||
|
server server1 127.0.0.1:5000 maxconn 32
|
@ -32,10 +32,11 @@
|
|||||||
virtualenv: /home/octoprint
|
virtualenv: /home/octoprint
|
||||||
name:
|
name:
|
||||||
- https://github.com/jneilliii/OctoPrint-BedLevelVisualizer/archive/master.zip
|
- https://github.com/jneilliii/OctoPrint-BedLevelVisualizer/archive/master.zip
|
||||||
- https://github.com/paukstelis/OctoPrint-Cancelobject/archive/master.zip
|
- https://github.com/jneilliii/OctoPrint-PrusaSlicerThumbnails/archive/master.zip
|
||||||
- https://github.com/OllisGit/OctoPrint-DeleteAfterPrint/releases/latest/download/master.zip
|
|
||||||
- https://github.com/malnvenshorn/OctoPrint-FilamentManager/archive/master.zip
|
|
||||||
- https://github.com/juniorRubyist/OctoPrint-OctoFlat/archive/master.zip
|
- https://github.com/juniorRubyist/OctoPrint-OctoFlat/archive/master.zip
|
||||||
- https://github.com/kanocz/octopi_eta_override/archive/master.zip
|
- https://github.com/kanocz/octopi_eta_override/archive/master.zip
|
||||||
- https://github.com/Renaud11232/OctoPrint-Resource-Monitor/archive/master.zip
|
- https://github.com/malnvenshorn/OctoPrint-FilamentManager/archive/master.zip
|
||||||
|
- https://github.com/OllisGit/OctoPrint-DeleteAfterPrint/releases/latest/download/master.zip
|
||||||
- https://github.com/OllisGit/OctoPrint-PrintJobHistory/releases/latest/download/master.zip
|
- https://github.com/OllisGit/OctoPrint-PrintJobHistory/releases/latest/download/master.zip
|
||||||
|
- https://github.com/paukstelis/OctoPrint-Cancelobject/archive/master.zip
|
||||||
|
- https://github.com/Renaud11232/OctoPrint-Resource-Monitor/archive/master.zip
|
||||||
|
@ -5,3 +5,4 @@
|
|||||||
|
|
||||||
- import_tasks: service.yml
|
- import_tasks: service.yml
|
||||||
|
|
||||||
|
- import_tasks: proxy.yml
|
||||||
|
19
roles/octoprint/tasks/proxy.yml
Normal file
19
roles/octoprint/tasks/proxy.yml
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
---
|
||||||
|
- become: yes
|
||||||
|
block:
|
||||||
|
- name: install needed tools
|
||||||
|
apt:
|
||||||
|
update_cache: yes
|
||||||
|
pkg:
|
||||||
|
- haproxy
|
||||||
|
|
||||||
|
- name: copy ha config
|
||||||
|
copy:
|
||||||
|
src: etc/haproxy/haproxy.cfg
|
||||||
|
dest: /etc/haproxy/haproxy.cfg
|
||||||
|
|
||||||
|
- name: restart haproxy
|
||||||
|
systemd:
|
||||||
|
state: restarted
|
||||||
|
daemon_reload: yes
|
||||||
|
name: haproxy
|
Loading…
Reference in New Issue
Block a user