Open troubledguy opened 3 years ago
I'm having the same isue.
I don't know if this works on any other desktop environments, but if you are using GNOME just put this in ~/.config/autostart/ProtonVPN-Reconnect.desktop:
[Desktop Entry] Name=ProtonVPN-Reconnect Comment=Automatically reconnect to ProtonVPN at startup Exec=/usr/bin/protonvpn-cli reconnect Terminal=false Type=Application X-GNOME-Autostart-enabled=true
That said, I use the official packages and not from PyPI
thank you @tommytran732 I did this on arch kde and it works!
for anyone to copy paste
nano ~/.config/autostart/ProtonVPN-Reconnect.desktop
Whenever I restart my computer, I check my vpn status to see that I am not connected despite having enabled autoconnect.
Steps to reproduce the behavior:
Error: Running "sudo systemctl status protonvpn-autoconnect.service" in the terminal, it poops out the following message:
protonvpn-autoconnect.service - ProtonVPN-CLI auto-connect Loaded: loaded (/etc/systemd/system/protonvpn-autoconnect.service; enabled; vendor preset: enabled) Active: failed (Result: exit-code) since Thu 2021-04-08 16:20:38 BST; 13min ago
Apr 08 16:20:38 Computerbox protonvpn[587]: File "/usr/local/lib/python3.8/dist-packages/protonvpn_cli/connection.py", line 15, in
Apr 08 16:20:38 Computerbox protonvpn[587]: from .logger import logger
Apr 08 16:20:38 Computerbox protonvpn[587]: File "/usr/local/lib/python3.8/dist-packages/protonvpn_cli/logger.py", line 40, in
Apr 08 16:20:38 Computerbox protonvpn[587]: logger = get_logger()
Apr 08 16:20:38 Computerbox protonvpn[587]: File "/usr/local/lib/python3.8/dist-packages/protonvpn_cli/logger.py", line 20, in get_logger
Apr 08 16:20:38 Computerbox protonvpn[587]: os.mkdir(CONFIG_DIR)
Apr 08 16:20:38 Computerbox protonvpn[587]: FileNotFoundError: [Errno 2] No such file or directory: '~[My openvpn username]/.pvpn-cli'
Apr 08 16:20:38 Computerbox systemd[1]: protonvpn-autoconnect.service: Control process exited, code=exited, status=1/FAILURE
Apr 08 16:20:38 Computerbox systemd[1]: protonvpn-autoconnect.service: Failed with result 'exit-code'.
Apr 08 16:20:38 Computerbox systemd[1]: Failed to start ProtonVPN-CLI auto-connect.
However, I am able to manually connect using protonvpn-cli commands with no issue apart from not being able to connect automatically at boot.
Desktop (please complete the following information):
Additional context I did install some protonvpn packages to connect directly to vpn. Although it didn't have autoconnect so I installed protonvpn-cli yesterday. I am also running this on a VM version of ubuntu.