So we've been running into some errors lately with our scripts, specifically (and at very random times) an exception is thrown because the BoxStarter.log file (in C:\Users[InstalledUnderUsername]\AppData\Local\Boxstarter) is locked due to multiple threads
trying to write to it at the same time. At first seemed extremely odd because folks were running PowerShell scripts that had absolutely nothing to do with BoxStarter. After a fair amount of digging I was able to determine that the following call was causing
BoxStarter to echo all PowerShell output to the file:
Set-BoxstarterConfig -LocalRepo "[\\OurInternal\boxStarterRepo"]
If I make sure none of our scripts call this then the issue never occurs.
Question 1: What is causing the redirect to happen (unless I'm missing something I can't find anything in the BoxStarter f() that would cause that behavior)?
Question 2: Does this function need to be called more than once (i.e. after BoxStarter is installed, after a machine has rebooted, in new sessions, etc.)?
Question 3: If yes to question 2, how do I prevent BoxStarter from opening and writing everything to the log file anytime Set-BoxStarterConfig is called?
Thanks in advance!