Commit graph

537 commits

Author SHA1 Message Date
Raphael Dannecker
9f1c60eefd Use variable instead of group membership to install localhome
Use variable localhome to determines whether the localhome module is installed.
Default: localhome=false

Further changes:
- Move pam-exec from common-auth to common-session
- Move pam-mkhomedir before pam-mount to avoid double login on first use
  on localhome devices
2025-03-19 11:08:57 +01:00
Raphael Dannecker
3d01394820 Separate exam-mode stuff in own role 2025-03-18 14:37:13 +01:00
Raphael Dannecker
43157dd810 Restart libvirtd after firewalld.service restart
Starting libvirtd.service provides iptable rules for NATed network virbr0.
When starting firewalld.service after libvirtd, these rules will be
overwritten. So NAT will no longer work. Restart of libvirtd fixes the
rules again.
2025-03-18 12:45:46 +01:00
Finn Hercke
4b982205ba Revoke already issued certificates on re-enroll 2025-03-11 12:49:33 +01:00
Raphael Dannecker
831f453512 Configuring the NFS server using variables is more customizable 2025-03-02 11:12:16 +01:00
Raphael Dannecker
18b2cb8ccf Add TPM support for win11 VMs 2025-02-27 19:21:49 +01:00
Raphael Dannecker
e418ab6189 Add requested packages 2025-02-27 18:39:00 +01:00
Raphael Dannecker
5b4a287cca Direct logout, when mount of server shares failed
Sometimes mounting the server shares fails when logging in (missing
krb5-tickts). On devices with localhome, users can still log in. To
prevent this, users are immediately logged out if the server mounts are
missing.
2025-02-27 18:34:44 +01:00
Raphael Dannecker
843289d2c2 Create generic wlan role
When implementing different wlan authentication modes (PSK/802-1x), we
have to separate general wlan stuff in one generic role.
2025-02-27 12:28:21 +01:00
Raphael Dannecker
72340155ed Correct ansible syntax to pass ansible-lint 2025-02-27 12:20:57 +01:00
Finn Hercke
f447d1dca6 Added support for 802-1X wifi-authentification and certificate-rollout on clients 2025-02-24 12:40:33 +01:00
Raphael Dannecker
97b9ba8d97 Shorten path for XDG_CONFIG_HOME and clean dir
In Linux socket paths are limited to 108 char length.
/var/tmp/vm/$UID/.config will be too long in some cases.
So we use /var/tmp/vm/$UID

/var/tmp/vm must be
- cleaned on startup
- created with sticky-bit (used by different users)
2025-02-18 14:16:56 +01:00
Raphael Dannecker
bde276d962 Exit pam_exec script when not running as root
When terminating screen lock, pam_exec is called in the context of the corresponding user.
Non-root users don't have the permission to start/stop firewalld. So exit immediately.
2025-02-14 08:45:37 +01:00
Raphael Dannecker
8b57bef7f8 Add missing file for commit e3396ef 2025-02-05 13:57:07 +01:00
Raphael Dannecker
76c2c38800 Revert "Adjust mmcblk-device gid on teacherlaptops to permit teachers access."
This reverts commit 640f58996c.
2025-02-05 13:22:23 +01:00
Raphael Dannecker
e3396ef06c Start firewalld when -exam user logs in 2025-02-05 13:15:42 +01:00
Raphael Dannecker
6dcbb03601 Allow domain users to write sd-cards 2025-02-05 13:10:56 +01:00
Raphael Dannecker
dfa16402f1 Set default git branch to main 2025-02-03 08:10:09 +01:00
Raphael Dannecker
5998c5900e Trixies uses tmpfs for /tmp, so let's use /var/tmp/vm for temporary VM files 2025-01-27 17:11:12 +01:00
Raphael Dannecker
f4dffc06fc Rename instead of delete -exam media directories (belongs to commit 39da308) 2025-01-27 17:01:03 +01:00
Raphael Dannecker
d5f9bb889b Some internet connections need smaller MTU for wireguard 2025-01-22 14:43:16 +01:00
Raphael Dannecker
18cde94846 Mount nfs share for additional programs and data 2025-01-22 14:40:52 +01:00
Raphael Dannecker
a6eadce948 Sync application starters on boot and separate ansible tasks from lmn_vm role 2025-01-22 14:36:38 +01:00
Raphael Dannecker
39da308ff7 Rename instead of delete outdated exam-user directories on localhome-clients
Exam mode don't collect home-directories on localhome clients.
Deleting home of exam-users will result in potential data loss. But keeping
the home under the same name will prevent new exam at the next day.

Solution: Rename home (and /lmn/media/) of user after 12h and delete after 10d.
2025-01-22 09:40:27 +01:00
Raphael Dannecker
727922f152 Prevent autoremove of libreoffice-qt5 (e.g. filepicker) 2025-01-20 15:54:56 +01:00
Raphael Dannecker
9c8a8bdc69 Increase minimum available disk space after downloading a new vm image 2025-01-15 12:22:37 +01:00
Raphael Dannecker
7db755e718 Add alternative git GUI 2025-01-13 13:49:26 +01:00
Raphael Dannecker
6c81e93937 Restore SDDM-Config when the primary screen patch is no longer needed 2025-01-13 13:43:24 +01:00
Raphael Dannecker
352a897d88 Start user-squid-proxy at login so that all programs without kerberos support have proxy access 2025-01-09 12:31:24 +01:00
Raphael Dannecker
f5f3d9557d Add missing file for commit 23a9b6f 2024-12-13 18:40:42 +01:00
Raphael Dannecker
a507c1decf Downloading changed images takes a lot of time, so let's ask the user before 2024-12-11 13:38:05 +01:00
Raphael Dannecker
23a9b6ff97 Enable firewall activation for exam-mode
For working exam-mode we need to block direct internet access by firewall.
Users have to use squid-proxy on firewall, which can be disabled for exam-users.
To allow VM-traffic (anonymous user), we use a local squid server with users
kerberos-ticket to authenticate on the parent squid.

When using VMs on teacherdevices offsite, the local squid has to use direct internet access.
So we need two squid configs. When switching between offsite and onsite,
the squid has to be restartet with corresponding config.
2024-12-11 13:09:30 +01:00
Raphael Dannecker
99d7bd64db Exam users uid always changes, therefore their home directory must be deleted 2024-12-04 12:08:28 +01:00
Raphael Dannecker
3ff31771f7 The path for the persistent VMs was incorrectly not always set 2024-11-27 18:29:39 +01:00
Raphael Dannecker
1a48d82224 Prevent wasting disk space by accident 2024-11-27 12:04:43 +01:00
Andreas B. Mundt
77f4643628 Make tests for group membership more readable 2024-11-21 12:42:37 +01:00
Andreas B. Mundt
8a25609749 Fix/update firefox bookmark menu 2024-11-21 12:42:37 +01:00
Raphael Dannecker
5fa626a598 Install required lib for zotero 2024-11-13 11:27:49 +01:00
Andreas B. Mundt
1f2e88da6e Run apt-daily early to avoid outdated package lists 2024-11-08 11:57:38 +01:00
Raphael Dannecker
c909f222a4 New PCs need more time before the screen resolution can be fixed 2024-11-06 09:50:48 +01:00
Raphael Dannecker
b1816effdb create a list of network drives that can be mounted in the VM
Some Windows programs have problems with virtiofsd drives.
So that the appropriate SMB shares can be mounted directly in Windows,
a corresponding list of network drives is created before the VM starts.
2024-11-04 18:26:53 +01:00
Raphael Dannecker
b8d9886054 Fix dolphin places config (user-places.xbel)
Existing dolphin configs can be incorrect for two reasons:
- Instead of the class identifier, a * was incorrectly entered in the home@server URL.
- If the student has changed classes, the old class name is still in the home URL.

lmn-patch-dolphin.sh no longer enters a * in the home@server URL.
lmn-fixhome-dolphin.sh will fix existing configs.
2024-10-31 17:28:16 +01:00
Raphael Dannecker
4c076e54f8 Fix patch-dolphin script (patch syntax for empty lines) 2024-10-14 15:10:17 +02:00
Raphael Dannecker
c068e85339 Fix primary screen for class room PCs with projector
Fixed EDID modes are set on the HDMI switch (ACER 120Hz problem).
This means that the affected PCs always see a second screen, even if beamer is off.

To avoid confusion, it must be ensured that no information is displayed on invisible devices:
- set primary screen for login dialog
- set primary screen after login
- clone screen
If the primary screen deviates from the standard, this information is maintained via inventory.

In addition, some PCs have different audio autputs than HDMI (or they have multiple HDMI outputs).
It is therefore possible to specify the audio device in the inventory.
2024-10-14 14:49:25 +02:00
Raphael Dannecker
317471011c Add package jq, needed for fixscreen (scale) starter 2024-09-25 08:44:43 +02:00
Raphael Dannecker
24af67384d Provide Nextcloud tools for teacherlaptops 2024-09-08 18:24:53 +02:00
Raphael Dannecker
2c201e160e Improve printer installation on teacherlaptops
- Update printer list when connected via VPN
- Prevent printer removal, when logging in without a connection to the school network
2024-09-08 11:35:12 +02:00
Raphael Dannecker
f9c0202107 Use KDE filepicker in Firefox, Thunderbird, ... 2024-09-06 08:13:48 +02:00
Andreas B. Mundt
5192b27d9e Move ansible last run stamping to better location
Before, only root could read the file containing the stamps.
2024-07-24 08:50:20 +02:00
Raphael Dannecker
962dc07a2a Make wg configuration an optional task
During installation and automatic updates applied by the emmiter
permissions to access the wg server are not available.

Switch the task on with the tag: "--tags all,wgconfig".
2024-07-24 08:41:58 +02:00