Hello Oleksandr,
1. One of our installers is used to install the Web application in IIS. And it also places the Web application files on the file system.
Our Web application is pre-compiled during the build, but it is updatable. Thus we have a lot of files like *.ascx, *asax, etc. on the file system.
We use the option "Synchronize content with folder from disk" in *.aip project file for the folder containing his Web application.
But if we go to the Features ("Organization" pane in *.aip), we'll see a lot components with strange names based on file names in the Web application which are picked up randomly.
Questions: is it necessary to store the references to all these files in *.aip project file and add a lot of components based on that information since the Web application folder is marked as "Synchronized"?
It is big issue for us since the Web app is constantly updated by developers, and I need to open the *.aip project from time to time to keep it up-to date with the latest content.
Wouldn't it be easier to make Advanced Installer pick up its contents automatically while building and add to the MSI file?
Please keep in mind this is the normal behavior. All resource files added in your project should be included in a component. So, when the synchronization is refreshed all resource files added in your synchronized folder will be automatically included in specific components.
2. We have a bunch of sub-folders under the parent Web app folder on the "Files and Folders" pane in the *.aip project file.
All of these sub-folders contain only log4net.config and Web.config files, also they are marked as "Synchronized" too and have "Install folder content into the parent folder" option checked.
For every of these folder the component with specific name is created. Every component has its Install Condition set based on the value selected on UI.
Thus during the installtion end-user selects proper configuration and both log4net.config and Web.config files are placed into the Web application root folder replacing the existing ones (this is the step where we faced with a problem when installation failed because the Web.config file from configuration sub-folder was read-only).
To overcome the problem in item 1 we tried the following: we deleted the entire contents of the folder (that is marked as "Synchronized" in our *.aip project file) from file system.
Then we reopened it, thus we reduced its size drastically and a lot of components (see item 1) were removed too (automatically).
Then we checked-in the *.aip project file into TFS, thus it was retrieved and built by the next build process.
Then we tried to install it and figured out that neither Web.config nor log4net.config were replaced.
In other words, the Install Condition wasn't evaluated properly.
We also tried to remove the contents of all these sub-folders from the file system. The result was the same.
Questions: is it expected behavior? Why isn't the Install Condition evaluated or even why isn't it taken into account?
How can we make Advanced Installer add "Synchronized" folders without producing a lot of components (we are curious why it is produced at all since the folder content should be synchronized while building and who knows what the content can be)?
I'm not sure why you are encountering this behavior. Can you please send us the .AIP (project file) and a
verbose log of the installation to
support at advancedinstaller dot com so we can investigate them?
3. Based on items 1 and 2 we decided to keep everything in the *.aip project file as it was.
But since a lot of components were generated we decided to rename them according to the folder's structure (e.g. if the parent folder named Web contains sub-folder named UserControls, the component was named Web_UserControls, if a sub-folder was named App_Themes, then the component was renamed to Web_App.Themes, etc.).
After renaming and reorganizing all the components, we build the project file again and noticed that new components containing only folders were added.
These components were named like Config_1, Config_2, etc. We moved these resources to appropriate components, but after building they appeared again.
We decided that the names of these components were generated baed on each folder's identifier that can be seen on the Properties dialog box.
Thus we renamed all the indetifiers (some of them were renamed in this dialog box, but some of them couldn't be renamed this way, so we opened the *.aip project file in Notepad++ and replaced them accordingly).
Renaming was done following the same rule that was described above for the components (but only adding "_Dir" to the end).
But after building the project file we saw the same components with strange names (like Config_1, Config_2) in the features.
Moreover, the Web.config and log4net.config files weren't replaced during the installation.
Questions: is there any rule how to name components and identifiers?
Please keep in mind that component names and folders identifiers should be unique.
Why some identifiers can be changed in Properties dialog box and some cannot (the folders are exactly the same, I mean synchronized sub-folders containing configuration)?
Indeed, this seems to be an Advanced Installer limitation. A improvement will be included in a future version of Advanced Installer, thank you for bringing this to our attention.
4. Besides we need to set the particular permissions for the APPDIR during the installation (e.g. Full Control for Administrators and Read & Execute, List folder content and Read for both Users and Authenticated Users).
We set these permissions on the APPDIR on the Permissions tab in Properties dialog box and checked "Apply permissions to all subfolders".
These permissions were applied correctly during the installation.
But whenever we add new configuration sub-folder (see item 2) that is synchronized and then open the Properties dialog box on Permissions tab and click OK and reopen again, all the permissions disappear.
We checked the *.aip file in Notepad++ and noticed that it did still contain the information about permission for all the sub-folders, but they were deleted for APPDIR.
In fact, these permissions sometimes disappear even without opening Properties dialog box for APPDIR.
Questions: is it possible to preserve these permissions despite the action being performed?
This may be caused by a recent bug in Advanced Installer which has been fixed in our latest version (9.9). So, can you test the scenario using latest version (9.9) of Advanced Installer and see if the behavior still reproduces?
All the best,
Daniel
FOLLOW US
Get the latest news in Application Packaging