diff options
-rwxr-xr-x | local/bin/lxc-net | 1 | ||||
-rw-r--r-- | profile | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/local/bin/lxc-net b/local/bin/lxc-net index 0821571..a9f1d10 100755 --- a/local/bin/lxc-net +++ b/local/bin/lxc-net @@ -1,4 +1,5 @@ #!/bin/sh +set -e if [ "$(id -u)" -ne 0 ]; then echo "Root required for execution" >&2 @@ -7,3 +7,5 @@ pulseaudio --start 2>/dev/null mpd ~/.config/mpd/mpd.conf # Start email synchronization ~/.local/sbin/syncemail +# And if we are on first terminal also automatically start x server +[ "$(tty)" = "/dev/tty1" ] && startx |