First, because you're about not to use terminal, I change sudo
to gksu
. And then, if you've created a script like this:
#!/bin/sh
gksu openvpn --config /home/ubuntu/Documents/vpnbook/vpnbook-euro2-udp25000.ovpn --auth-user-pass /home/ubuntu/Documents/vpnbook/password.txt
and named it your-script.sh
, you can create a file like this (taken from this answer):
#!/usr/bin/env xdg-open
[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Exec=</Path/to/your-script.sh>
Name=<Enter visible name here>
Comment=<Enter comment here>
Icon=</Path/to/icon/you/like>
For example, you named the file your-launcher.desktop
. Place it in ~/.local/share/applications/
, open nautilus and drag-and-drop your-launcher.desktop
into the Unity launcher.
Besides that, maybe (but I've not tested yet) you can place gksu openvpn --config /home/ubuntu/Documents/vpnbook/vpnbook-euro2-udp25000.ovpn --auth-user-pass /home/ubuntu/Documents/vpnbook/password.txt
directly in Exec
field of your-launcher.desktop
.