I'm trying to connect with my_profile_name profile from shell with android
am command. Playing around it I got working solution for OpenVPN Connect 1.1.27:
am start -n net.openvpn.openvpn/net.openvpn.openvpn.OpenVPNClient \
-a android.intent.action.VIEW \
--es net.openvpn.openvpn.AUTOSTART_PROFILE_NAME my_profile_name
Does anyone know how to run same stuff with 3.0+ version?
Based on Tasker FAQ
https://docs.openvpn.net/faqs/faq-regarding-openvpn-connect-android/#How_do_I_use_tasker_with_OpenVPN_Connect_for_Android here is what I try:
am start -n net.openvpn.openvpn/net.openvpn.unified.MainActivity \
-a net.openvpn.openvpn.CONNECT \
--es net.openvpn.openvpn.APP_SECTION PC \
--es net.openvpn.openvpn.AUTOSTART_PROFILE_NAME "PC my_profile_name" \
--ez net.openvpn.openvpn.AUTOCONNECT true
I've tried different combinations of extras but it just opens PC section of the app. Thanks for suggestions.