1
0
forked from infra/ansible
infra/roles/xrdp_apphost/tasks/estlcam.yml
Thomas Basler 2d645a13f4 xrdp_apphost: Implemented cleanup of old files
All files older than 30 days as well as empty folders
will be automatically deleted.
2022-06-19 21:47:48 +02:00

44 lines
1.2 KiB
YAML

---
- name: Enable contrib repositories
apt_repository:
repo: deb http://deb.debian.org/debian {{ ansible_distribution_release }} contrib
- name: Add i386 Architecture
command: dpkg --add-architecture i386
args:
creates: /var/lib/dpkg/arch
when: ansible_architecture != 'i386'
register: archrc
- name: Update APT Cache for i386
apt:
update_cache: true
when: archrc is defined and archrc.changed
- name: Install Estlcam dependencies
apt:
name:
- winetricks
- wine32
- xfwm4
- name: Create Estlcam group
group: name={{ estlcam_group }}
- name: Create Estlcam user
user: name={{ estlcam_user }} password={{ estlcam_pass | password_hash('sha512', estlcam_salt) }} home=/home/{{ estlcam_user }} group={{ estlcam_group }}
- name: Create Estlcam .xsession
template: src=estlcam_xsession.j2 dest=/home/{{ estlcam_user }}/.xsession
- name: Create Estlcam data directory
file: path=/home/{{ estlcam_user }}/data state=directory mode=0755 owner={{ estlcam_user }} group={{ estlcam_group }}
- name: Create info directory
file:
path: "/home/{{ estlcam_user }}/data/{{ info_folder_name }}"
state: directory
mode: 0444
owner: root
group: root