Created
June 15, 2016 12:18
-
-
Save il-katta/c3acff61d486bd48b928d6d53dcd9d7f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description = Virtualbox VM | |
After = systemd-user-sessions.service network.target sound.target | |
ConditionPathExists = /dev/tty0 | |
[Service] | |
Type = simple | |
TTYPath = /dev/tty8 | |
StandardInput = tty | |
StandardOutput = tty | |
# Reset the terminal device specified with TTYPath= | |
# before and after execution. | |
TTYReset = yes | |
TTYVHangup = yes | |
# clear the screeen | |
TTYVTDisallocate=yes | |
PermissionsStartOnly = true | |
User = < YOU USER > | |
Group = vboxusers | |
PAMName = login | |
ExecStart = /usr/bin/xinit /usr/bin/dbus-launch --exit-with-session \ | |
/usr/lib/virtualbox/VirtualBox --startvm "%i" --fullscreen --no-startvm-errormsgbox -- \ | |
:1 -nolisten tcp vt8 | |
ExecStop = /usr/bin/VBoxManage controlvm "%i" poweroff | |
Restart = on-abort | |
RestartSec = 5 | |
SyslogIdentifier = virtualbox-%i | |
[Install] | |
WantedBy = multi-user.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment