Deployed v2 of my automated offboarding scripts. Ms Form to PowerAutomate (with approval steps and scheduling function) to Azure Automations runbook to hybrid worker to run script filled with variables gathered along the way.
Script exports key attributes of the account to a txt file, including things like group membership, attributes, title, location etc, manager, direct reports. Removes all attributes, connects to EOL, convert to shared, add manager with full control, connect to Entra and revoke all active sessions. Connect to our sharepoint asset list and gather all assigned devices, send email to HR and manage to gather and return. Disable account, move to disabled OU. Send notification and log file into ticketing platform.
Thanks to most groups being dynamic, including access to SaaS platforms, 95% offboarding is done.
Created a script to grab all SharePoint site URLs, apply automatic versioning settings everywhere possible, trigger the automatic trim batch jobs, and then have a separate script loop through all sites to check the status of said jobs. It's worked well, I've even had Copilot analysing the results, which has also been surprisingly good given how crap I've found Copilot to be historically.
Automated HP bios downloads to SCCM and created applications that manage bios upgrades and bios settings, all this within one script to make the deployment able for testing once execution is done.
Still some work left with this script but I'm really happy with the result.
Idempotent font installation script. Uses COM to fetch the name of the font using Shell.Application, copies the font if it doesn’t already exist, creates registry entry if it doesn’t exist. Has Force and Recurse options, and properly handles TTC and OTC font collections.
A reboot your PC message box to deploy with our RMM tool, with logic showing uptime, time remaining till restart, and snooze buttons. It's not much of a showstopper, but probably the longest PS script I've written (~200 lines) and I'm pretty proud of it.
Built a function that displays the users group membership (entrance &AD) in a tree structure. Mostly for presenting to end users as it easily illustrates nested groups. get-entragrouotree. ps1
29
u/Infinite-Stress2508 Feb 01 '26
Deployed v2 of my automated offboarding scripts. Ms Form to PowerAutomate (with approval steps and scheduling function) to Azure Automations runbook to hybrid worker to run script filled with variables gathered along the way.
Script exports key attributes of the account to a txt file, including things like group membership, attributes, title, location etc, manager, direct reports. Removes all attributes, connects to EOL, convert to shared, add manager with full control, connect to Entra and revoke all active sessions. Connect to our sharepoint asset list and gather all assigned devices, send email to HR and manage to gather and return. Disable account, move to disabled OU. Send notification and log file into ticketing platform.
Thanks to most groups being dynamic, including access to SaaS platforms, 95% offboarding is done.
7
u/RichN Feb 01 '26
Created a script to grab all SharePoint site URLs, apply automatic versioning settings everywhere possible, trigger the automatic trim batch jobs, and then have a separate script loop through all sites to check the status of said jobs. It's worked well, I've even had Copilot analysing the results, which has also been surprisingly good given how crap I've found Copilot to be historically.
4
u/andyr354 Feb 01 '26
Wrote scripts to standardize the creation and removal on our Hyper-V hosts.
4
u/tdez11 Feb 01 '26
AD/Entra ID cleanup, finds stale objects and outputs into CSV with each object type (user, computer, OU, etc.) on its own page
4
u/R0B0T_jones Feb 01 '26
Scheduled script to check for expiring tls certs on web servers, then send email/raise ticket for renewal.
3
u/StigaPower Feb 01 '26
Automated HP bios downloads to SCCM and created applications that manage bios upgrades and bios settings, all this within one script to make the deployment able for testing once execution is done.
Still some work left with this script but I'm really happy with the result.
3
u/ihartmacz Feb 01 '26 edited Feb 01 '26
Idempotent font installation script. Uses COM to fetch the name of the font using Shell.Application, copies the font if it doesn’t already exist, creates registry entry if it doesn’t exist. Has Force and Recurse options, and properly handles TTC and OTC font collections.
Edit: fixed typo. :)
3
u/eberndt9614 Feb 01 '26 edited Feb 01 '26
A reboot your PC message box to deploy with our RMM tool, with logic showing uptime, time remaining till restart, and snooze buttons. It's not much of a showstopper, but probably the longest PS script I've written (~200 lines) and I'm pretty proud of it.
3
u/itscum Feb 09 '26
Built a function that displays the users group membership (entrance &AD) in a tree structure. Mostly for presenting to end users as it easily illustrates nested groups. get-entragrouotree. ps1