This commit is contained in:
2021-08-13 19:34:20 +02:00
parent ddaac9259b
commit 99eae0bbbd
4 changed files with 47 additions and 12 deletions

View File

@ -18,7 +18,26 @@
state: present
vars:
packages:
- x11vnc
- x11vnc
- name: "(ubuntu-x11vnc-1804-amd64.yml) get numeric id for group 'gdm'"
shell: echo "$(id -u gdm)"
register: grp_id_gdm
- name: Check if file '/etc/gdm3/custom.conf' exists
stat:
path: /etc/gdm3/custom.conf
register: etc_gdm_custom_conf_exists
- name: Adjust file '/etc/gdm3/custom.conf'
lineinfile:
dest: /etc/gdm3/custom.conf
state: present
regexp: '^WaylandEnable'
line: 'WaylandEnable=false'
insertafter: '^#?\s*WaylandEnable'
when:
- etc_gdm_custom_conf_exists.stat.exists
- name: "(ubuntu-x11vnc-1804-amd64.yml) Store password"
raw: "x11vnc -storepasswd {{ vnc_password }} /etc/x11vnc.pass"
@ -30,7 +49,7 @@
- name: "(ubuntu-x11vnc-1804-amd64.yml) Transfer x11vnc.service.j2 to /lib/systemd/system/x11vnc.service"
template:
src: lib/systemd/system/x11vnc.service.j2
src: lib/systemd/system/x11vnc-gdm3.service.j2
dest: /lib/systemd/system/x11vnc.service
- name: "(ubuntu-x11vnc-1804-amd64.yml) Enable service"