xrdp_apphost: Add configuration for Slic3r

This commit is contained in:
Thomas Basler 2022-01-08 03:39:36 +01:00
parent 9c2cf94ea2
commit f565853cd2
7 changed files with 59 additions and 0 deletions

View File

@ -36,6 +36,16 @@ estlcam_group: estlcam
estlcam_pass: fckgw01estlcam
estlcam_salt: $1$SomeSalt$
slicer_user: slicer
slicer_group: slicer
slicer_pass: fckgw01slicer
slicer_salt: $1$SomeSalt$
slicer_checksum: sha256:b6c34157ff2acffae5b39a1997f5694e9ca4717d5c9b370f75a6728eeadb9cab
slicer_version: 2.4.0+linux-x64-202112211614
slicer_url: https://github.com/prusa3d/PrusaSlicer/releases/download/version_2.4.0/PrusaSlicer-{{ slicer_version }}.AppImage
slicer_target: /home/{{ slicer_user }}/PrusaSlicer-{{ slicer_version }}.AppImage
tsadmin_user: tsadmin
tsadmin_group: tsadmin
tsadmin_pass: fckgw01tsadmin

View File

@ -3,6 +3,7 @@
- include: xrdp.yml
- include: lightburn.yml
- include: estlcam.yml
- include: slicer.yml
- include: samba.yml
@ -22,6 +23,7 @@
with_items:
- "{{ estlcam_user }}"
- "{{ lightburn_user }}"
- "{{ slicer_user }}"
- name: Create tsadmin_user .xsession
template: src=tsadmin_xsession.j2 dest=/home/{{ tsadmin_user }}/.xsession

View File

@ -0,0 +1,21 @@
---
- name: Install Slic3r dependencies
apt:
name:
- libgtk2.0-0
- name: Create Slic3r group
group: name={{ slicer_group }}
- name: Create Slic3r user
user: name={{ slicer_user }} password={{ slicer_pass | password_hash('sha512', slicer_salt) }} home=/home/{{ slicer_user }} group={{ slicer_group }}
- name: Create Slic3r .xsession
template: src=slicer_xsession.j2 dest=/home/{{ slicer_user }}/.xsession
- name: Create Slic3r data directory
file: path=/home/{{ slicer_user }}/data state=directory mode=0755 owner={{ slicer_user }} group={{ slicer_group }}
- name: Download Slic3r binary
get_url: url={{ slicer_url }} dest={{ slicer_target }} checksum={{ slicer_checksum }} mode=0755

View File

@ -0,0 +1,4 @@
{{ ansible_managed | comment }}
matchbox-window-manager &
exec /home/{{ slicer_user }}/PrusaSlicer-{{ slicer_version }}.AppImage

View File

@ -259,3 +259,15 @@
directory mask = 0700
force user = {{ estlcam_user }}
hide dot files = yes
# Slicer share
[slicer]
comment = Slicer data folder
path = /home/{{ slicer_user }}/data
browseable = yes
read only = no
guest ok = yes
create mask = 0600
directory mask = 0700
force user = {{ slicer_user }}
hide dot files = yes

View File

@ -2,5 +2,6 @@
xhost si:localuser:{{ lightburn_user }}
xhost si:localuser:{{ estlcam_user }}
xhost si:localuser:{{ slicer_user }}
xfwm4 &
exec xterm

View File

@ -200,6 +200,15 @@ ip=127.0.0.1
port=-1
code=20
[Slicer]
name=Slicer
lib=libxup.so
username={{ slicer_user }}
password={{ slicer_pass }}
ip=127.0.0.1
port=-1
code=20
[Xorg]
name=Xorg
lib=libxup.so