Browse Source

disallow vncserver resize

pull/1/head
parent
commit
2064fee799
4 changed files with 16 additions and 1 deletions
  1. +6
    -0
      tasks/vnc.yaml
  2. +3
    -0
      templates/vnc/vncserver.env.j2
  3. +2
    -1
      templates/vnc/vncserver.service.j2
  4. +5
    -0
      vars/main.yaml

+ 6
- 0
tasks/vnc.yaml View File

@@ -12,6 +12,12 @@
dest: ~/.vnc/config
mode: 0644

- name: vnc env
template:
src: vnc/vncserver.env.j2
dest: ~/.vnc/vncserver.env
mode: 0644

- name: vnc server config
template:
src: vnc/vnc.conf.j2


+ 3
- 0
templates/vnc/vncserver.env.j2 View File

@@ -0,0 +1,3 @@
{{ ansible_managed | comment }}

VNCSERVER_OPTIONS="{{vncserver_options|replace('\n',' ')|trim}}"

+ 2
- 1
templates/vnc/vncserver.service.j2 View File

@@ -19,8 +19,9 @@ Description=vncserver service - display %i
After=syslog.target network.target

[Service]
EnvironmentFile=%h/.vnc/vncserver.env
Type=forking
ExecStart=/usr/bin/vncserver -autokill %i
ExecStart=/usr/bin/vncserver -autokill %i $VNCSERVER_OPTIONS
ExecStop=/usr/bin/vncserver -kill %i

[Install]


+ 5
- 0
vars/main.yaml View File

@@ -132,3 +132,8 @@ background_image_path: ~/.backgrounds/{{background_image|basename}}
background_command: feh --no-fehbg --bg-fill {{background_image_path}}

timer_folder: ~/.timer

vncserver_options: |
{% if not home_vncserver_allow_resize %}
-AcceptSetDesktopSize=0
{% endif %}