From 3228ad789206a2fd477060fa6849850af52523b1 Mon Sep 17 00:00:00 2001 From: Blake Matthes Date: Sun, 30 Mar 2025 08:41:55 -0500 Subject: [PATCH] feat(lst): script added for the test server to readd the permissions once it boots up --- server/scripts/updatePermissions.ps1 | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 server/scripts/updatePermissions.ps1 diff --git a/server/scripts/updatePermissions.ps1 b/server/scripts/updatePermissions.ps1 new file mode 100644 index 0000000..3399579 --- /dev/null +++ b/server/scripts/updatePermissions.ps1 @@ -0,0 +1,22 @@ +# Define the array of folders +$folders = @( +"AlplaBasis", +"AlplaBudget", +"AlplaINVOICE", +"AlplaLabel", +"AlplaOrder", +"AlplaPlanning", +"AlplaPurchase", +"AlplaStock", +"PDF24", +"Module shortcuts" +) + +# Set permissions using icacls +$permissions = "Everyone:(OI)(CI)F" + +# Loop through each folder and set permissions +foreach ($folder in $folders) { + $folderPath = "C:\Sources\AlplaPROD\$folder" + icacls $folderPath /grant $permissions /t /c /q +}