Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions ansible/roles/soe-gui/files/dconf-printscreen-rdp
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# PrtSc on a Mac keyboard reaches an RDP session as F13, which GNOME reads as XF86Tools.
# Deployed to /etc/dconf/db/local.d/10-printscreen-rdp. Run 'dconf update' after changes.

[org/gnome/shell/keybindings]
show-screenshot-ui=['Print', 'XF86Tools']

# XF86Tools opens Settings by default. Unbind it there so the screenshot binding gets the key.
[org/gnome/settings-daemon/plugins/media-keys]
control-center-static=@as []
10 changes: 10 additions & 0 deletions ansible/roles/soe-gui/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,16 @@
- ansible_facts['distribution'] in ['Fedora', 'Ubuntu']
- has_gnome | default(false)

- name: Bind PrtSc from Mac RDP clients to the GNOME screenshot UI
ansible.builtin.include_tasks:
file: printscreen.yml
apply:
tags: ['soe-gui', 'printscreen']
tags: ['soe-gui', 'printscreen']
when:
- ansible_facts['distribution'] in ['Fedora', 'Ubuntu']
- has_gnome | default(false)

# The GNOME desktop (extensions, dock, theming) is opt-in: it must only be
# configured when winlike or maclike is EXPLICITLY requested. A `never` tag
# alone cannot enforce that here, because the role-level tags are inherited by
Expand Down
35 changes: 35 additions & 0 deletions ansible/roles/soe-gui/tasks/printscreen.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
---
# PrtSc from a Mac RDP client (Thincast) arrives as F13, because macOS has no PrtSc key code. Bind its GNOME keysym, XF86Tools, to the screenshot UI.
# System-wide dconf default, so a user's own binding still wins.

- name: Ensure system dconf keyfile directory exists
ansible.builtin.file:
path: /etc/dconf/db/local.d
state: directory
mode: '0755'

- name: Ensure dconf user profile reads the local system-db
ansible.builtin.lineinfile:
path: /etc/dconf/profile/user
line: "{{ item }}"
create: true
mode: '0644'
loop:
- "user-db:user"
- "system-db:local"
register: printscreen_dconf_profile

- name: Deploy PrtSc-over-RDP screenshot binding
ansible.builtin.copy:
src: dconf-printscreen-rdp
dest: /etc/dconf/db/local.d/10-printscreen-rdp
owner: root
group: root
mode: '0644'
register: printscreen_dconf_deployed

- name: Update dconf database
ansible.builtin.command:
cmd: dconf update
changed_when: true
when: (printscreen_dconf_deployed.changed | default(false)) or (printscreen_dconf_profile.changed | default(false))
1 change: 1 addition & 0 deletions docs/install-matrix.md
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,7 @@ hyperi-ci.
| Slack | all | vendor-repo / cask |
| LibreOffice (org office suite) | Linux | distro repo |
| Nemo, GNOME extensions (gext), fonts | Linux | distro / uv-tool / vendored |
| PrtSc from a Mac RDP client (arrives as F13) opens the GNOME screenshot UI (tag `printscreen`) | Linux GNOME | system dconf |
| colima + Apple `container` (macOS only; `container` needs Apple silicon and macOS 26) | macOS | brew |
| Local ClickHouse + Redpanda (opt-in `soe_local_services_enabled`) | all | container image |
| removals / update_command / admin-scripts (opt-in `never`, on for soe) | Linux | tombstones + scripts |
Expand Down
Loading