If gdm supports running scripts when starting a greeter seession or right after stopping X, then it's doable.
These are the relevant fields in the lightdm configuration file:
# display-setup-script = Script to run when starting a greeter session (runs as root)
# display-stopped-script = Script to run after stopping the display server (runs as root)
If gdm supports running scripts when starting a greeter seession or right after stopping X, then it's doable.
These are the relevant fields in the lightdm configuration file:
# display- setup-script = Script to run when starting a greeter session (runs as root) stopped- script = Script to run after stopping the display server (runs as root)
# display-