Reboot that requires inventory refresh

Hi,

I have 2 VPN servers, and remote-random in VPN config, so clients connect to server1 or server2.

I need clients to reboot after major upgrades (new kernel), and the problem is that if the client connects to different VPN server, reboot module fails because it cannot connect any more to the client (to run test_command to see if the client rebooted successfully) using the old/wrong VPN server.

I found meta: refresh_inventory, but cannot figure out now can I refresh inventory in the middle of running the reboot module.

Help appreciated.

-Paavo

Ideally, inventory would be refreshes after each reboot connect_timeout to ensure the connection update will be taken into use.

perjantai 29. tammikuuta 2021 klo 10.54.30 UTC+2 Paavo Leinonen kirjoitti: