Support Forum
The Forums are a place to find answers on a range of Fortinet products from peers and product experts.
andrewmcdonald
New Contributor

Forti SSLVPNClient - getting Powershell to wait until the vpn client has connected

I want to run powershell scripts, that connect through our corporate VPN using forticlient, and when it has successfully connected start PSSessions to backups etc on remote servers If I run the script on a powershell cmd line entering the script line by line, it works if I wait for Forticlient to connect to the VPN and does all the rest If I put it in a Powershell .ps1 script it fails as it trys to do stuff on the remote servers before it has finished connecting to the VPN through forticlient Using FortiSSLVPNclient I have tried pipelining | Wait-Process at the end and | Out-Null but neiither of those commands seems to have any affect, and being a newbie at powershell doesn't help Anyone have idea what will work with the FortiSSLVPNclient to make it finish connecting before continuing with the scripts and trying to connect to remote servers ?

0 REPLIES 0
Announcements

Select Forum Responses to become Knowledge Articles!

Select the “Nominate to Knowledge Base” button to recommend a forum post to become a knowledge article.

Labels
Top Kudoed Authors