Custom action to run cacls
I don't know if anyone can help me with this, but it's worth a shot.
I have a small msi package I have created from a legacy install. I need to assign the local machine's "User" group more rights than the default inheritence from the system drive gives it. I had no luck assigning local groups permissions in Wise, and cannot find a good place in the install sequence to place this custom action. When the folder I am running cacls on already exists, it works perfectly.
The problem is, when the folder is not already there, it errors out. So it seems no matter where I place the custom action in the sequence, it is running before Windows Installer creates the installation directory that I want to run cacls on.
Might anyone be able to offer any insight?
Thanks.
I have a small msi package I have created from a legacy install. I need to assign the local machine's "User" group more rights than the default inheritence from the system drive gives it. I had no luck assigning local groups permissions in Wise, and cannot find a good place in the install sequence to place this custom action. When the folder I am running cacls on already exists, it works perfectly.
The problem is, when the folder is not already there, it errors out. So it seems no matter where I place the custom action in the sequence, it is running before Windows Installer creates the installation directory that I want to run cacls on.
Might anyone be able to offer any insight?
Thanks.
0 Comments
[ + ] Show comments
Answers (2)
Please log in to answer
Posted by:
WiseUser
18 years ago
Posted by:
Foleymon
18 years ago
WiseUser is right.
Put down xcacls.exe as a file in your package, I usually put it in the WINDOWS\SYSTEM32 dir.
1-Open up the MSI
2-On the bottom select 'MSI Script'
3-Select the 'Execute Immediate' tab
4-Find 'InstallFinalize' (down at the bottom usually)
5-From Actions choose Execute Program From Installation (or Path)
6-Hit F1 for help on exactly how to fill those fields out.
Your command line will look something like this.
%SYS%xcacls.exe "c:\Program Files\YOUR_PROGRAM" /t /e /c /g Users:F /y
Hope that helps.
Put down xcacls.exe as a file in your package, I usually put it in the WINDOWS\SYSTEM32 dir.
1-Open up the MSI
2-On the bottom select 'MSI Script'
3-Select the 'Execute Immediate' tab
4-Find 'InstallFinalize' (down at the bottom usually)
5-From Actions choose Execute Program From Installation (or Path)
6-Hit F1 for help on exactly how to fill those fields out.
Your command line will look something like this.
%SYS%xcacls.exe "c:\Program Files\YOUR_PROGRAM" /t /e /c /g Users:F /y
Hope that helps.
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.