Score:0

Enabling VNC server by script

th flag

First sorry for the english translated via google translator.

I'm in an environment where there are windows domain controllers and ubuntu 22.04 workstations, different users use the same desktops alternately with their credentials.

In this scenario, how would it be possible to enable the native VNC server through a script in the /etc/skel folder so that when the user logs in for the first time on the desktop, the vnc server is configured?

I've already tried installing apps like x11vnc, tightvnc, vnc4server, but I always find it difficult to export these settings to other users. I also tried inserting configuration commands at the end of the .profile file, it didn't work:

    gsettings set org.gnome.desktop.remote-desktop.vnc enable true
    gsettings set org.gnome.desktop.remote-desktop.vnc auth-method 'password'
    gsettings set org.gnome.desktop.remote-desktop.vnc view-only false
    echo -n 'senha001' | secret-tool store --label="GNOME Remote Desktop VNC password" "xdg:schema" "org.gnome.RemoteDesktop.VncPassword"
    systemctl --user start gnome-remote-desktop.service
    loginctl unlock-session $(loginctl --no-legend --value list-sessions | awk '/seat/ { print $1}')

the commands above even allow remote connection, but the screen is cut off in the upper left corner in the size of 800x600, hiding the rest of the original screen, making it impossible to access the dock that is in the bottom position

Printscreem

I hope someone can help me

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.