After messing with my Hosts File Updater script, I decided it needed an update. We’ve been messing with WPF and Powershell for a while now, and this would make the perfect candidate to showcase some WPF and runspaces.
We’ve recently been toying around with building a GUI for some of our web deployment functions, and naturally the project evolved over time. It started with building a UI in WPF, evolved to runspaces for performance gains, and finally ended at runspace pools for throttling. Through these evolutions, I’ve gained a considerable amount of knowledge in what can be done with Powershell.
While updating our Windows 10 images to the anniversary update (1607), I noticed that all the bloat I had already removed was added back. So I took this opportunity to brush up on some more Powershell and create a script that could help some other folks with the same issue!
This script has found itself being used for many other purposes than originally intended, not sure why it has taken me so long to post it! It was written to provide for an easy way to zip all of our IIS logs, and have them grouped by month created. It was originally setup to append .zip files with new data as needed but ,due to a bug in the write-zip cmdlet, I have changed it to ignore the last month of logs. I will leave the commented out code in this script, just in case they eventually fix the bug.
Our employee termination process involves several steps. While they don’t take too long to run through individually, time IS precious! Here is a script that I wrote to automate the majority of the tasks that we perform when someone chooses to leave RANDA. There’s even a fun “Finished” notification to make the painful process of someone leaving a bit more light hearted.
I recently began writing a script to automate tasks when an employee decides to leave RANDA, I may post it in its entirety at a later date. In doing so, I searched for a way to remove all Office 365 licenses assigned to a user. I could find nothing… So I came up with my own!
In a previous article I discussed my need for instant gratification when it comes to replicating my DC’s. I gave an example of a script that would replicate all the DC’s that are manually programmed into it.
Well, here is a solution that will find the DC’s on its own and then update each DC with its respective partner. A much simpler and elegant solution if I do say so myself!