Configure custom images as screen saver with idle time and slideshow styles
This Automox Worklet™ deploys custom images to macOS endpoints and configures them as the active screen saver. The Worklet extracts images from a zip file you upload, places them in a user-accessible directory, and applies screen saver settings including idle timeout and slideshow style.
The Worklet uses bash scripting to identify the logged-in console user, create the necessary directory structure, and write configuration values to the macOS defaults system. It handles file permissions, cleanup of temporary files, and supports both JPEG and PNG image formats.
When endpoints display default or user-selected images, sensitive information may appear on unattended displays, and screen savers can expose endpoints to social engineering if they don't reflect organizational identity. Unmanaged screen savers create security and branding risks that automated deployment eliminates.
Automating screen saver deployment through this Worklet maintains all endpoints display approved images and engage the display after consistent idle periods. This approach maintains corporate branding guidelines while reducing the time administrators spend manually configuring each user's preferences.
Evaluation phase: The Worklet script checks if the background directory and required image files exist in the user's Pictures folder location defined by the imageDir variable.
Remediation phase: The script creates the backgrounds directory if needed, extracts images from the uploaded zip file, synchronizes them to the target location, applies appropriate permissions, and writes screen saver defaults including idle timeout, clock display, module type, and slideshow style via the defaults command for the console user.
macOS 10.14 (Mojave) or later; validated on Catalina, Big Sur, and Monterey including M1 endpoints
A zip file containing image files in JPEG or PNG format; the default filename is backgrounds.zip but this can be customized via the zipName variable
Logged-in console user at time of Worklet execution; the script requires active user context to apply user-specific defaults
Ability to modify user-level defaults; the Worklet runs with elevated privileges to write to the com.apple.screensaver and com.apple.ScreenSaverPhotoChooser preferences
After successful execution, the screen saver will activate after the configured idle time (default 10 minutes) and display images in slideshow format from the Backgrounds directory. The images rotate through all items in the directory using the selected slideshow style. Users see the custom images applied immediately without requiring restart or logout, though some system preferences caching may delay visibility by several minutes. This automated deployment maintains all endpoints display approved images and consistent branding.
Verify success by checking the System Preferences > Desktop and Screen Saver settings for the console user, where the custom images now appear as the selected source. Also, examine the directory permissions on /Users/{username}/Pictures/Backgrounds to confirm images are readable by the user account. Subsequent Worklet evaluations confirm the configuration remains in place.
Run this Worklet on a pilot macOS endpoint and review evaluation output for set screen saver.
Confirm Automox activity logs show successful completion and exit code 0.
Verify endpoint state using checks aligned to evaluation script logic, such as exit.
Validate remediation effects from script operations such as mkdir, unzip, rsync, then rerun evaluation for compliance.


By submitting this form you agree to our Master Services Agreement and Privacy Policy.
Already have an account? Log in
Consider Worklets your easy button
A Worklet is an automation script, written in Bash or PowerShell, designed for seamless execution on endpoints – at scale – within the Automox platform. Worklet automation scripts perform configuration, remediation, and the installation or removal of applications and settings across Windows, macOS, and Linux.

AUTOMOX + WORKLETS™
Uncover new possibilities with simple, powerful automation.
By submitting this form you agree to our Master Services Agreement and Privacy Policy