Apply a Configuration Profile in a cron fashion

split_io
New Contributor II

Hi! I am guessing I can use the Jamf Pro API for this on a wrapper script cronned on GitHub Actions.
Could you please provide an example of using the API to re-apply en existing profile to the current laptops it is scoped?

Thanks!

IMPORTANT: If you wonder why I want to do this: It is because users need to disable Wandera for accessing certain wifi hotspots and sometimes they forget to re-enable it. Therefore, re-applying the profile to all the users will automatically re-enable Wandera for them.

1 REPLY 1

split_io
New Contributor II

I was thinking on something like this:

curl -X PUT \
https://split.jamfcloud.com/JSSResource/mobiledeviceconfigurationprofiles/id/39 \
    --header 'authorization: Basic MY_CREDENTIALS' \
    --header 'content-type: application/xml' \
    --data '<configuration_profile>
   <general>
       <redeploy_on_update>All</redeploy_on_update>
   </general>
   <scope>
       <all_computers>true</all_computers>
   </scope>
</configuration_profile>'

However, I don't know if this will automatically trigger the re-deployment of the profile since it is already scoped to "All Computers". Could somebody confirm?