Page 1 of 3

[Wapt - installation path]

Published: April 25, 2016 - 4:06 PM
by shirocen
Hello,

after successfully installing packages on a client, I'd like to specify their installation paths.

Currently, they all install directly to the C: drive, but I'd like them to install to the D: drive. After

consulting numerous articles to understand how to do this, I haven't found any solutions other than

the copytree2() function, which doesn't seem appropriate.

I only know that the modification must be done in setup.py.

Thanks in advance!

Re: [Wapt - installation path]

Published: April 25, 2016 - 5:57 PM
by sfonteneau
Good morning

I haven't tried it, but it should normally be okay

When creating a custom Waptagent: First, modify the file:

Code: Select all

C:\wapt\waptsetup\waptsetup.iss
and modify this line:
https://github.com/tranquilit/WAPT/blob ... up.iss#L31

Code: Select all

DefaultDirName="C:\wapt"
To replace it with whatever you want.

Then restart the generation of a Waptagent

Simon

Re: [Wapt - installation path]

Published: April 26, 2016 - 09:12
by shirocen
Thank you for your reply, Simon.

This command installs the agent in D:, but I would like to install the software sent from the WAPT console in D:

and not the agent. For example, when I install Firefox, the files are stored in C:. I would like to change this

behavior and redirect all installations to the D: drive.

Thank you in advance!

Re: [Wapt - installation path]

Published: April 26, 2016 - 10:38 AM
by sfonteneau
Ah yes, okay.

Well, you have two solutions. You need to modify all your WAPT packages to add options:

For example, for Firefox with: `InstallDirectoryPath=d:\firefox\`

https://wiki.mozilla.org/Installer:Comm ... _Arguments

The second solution is to move Program Files:

http://www.clubic.com/forum/microsoft-w ... page1.html

But this only solves the problem for software that installs in Program Files.

Re: [Wapt - installation path]

Published: April 26, 2016 - 10:55 AM
by shirocen
Thank you for your reply, Simon.

Is the line `InstallDirectoryPath=d:\firefox\` correct to add to the setup.py file?

Thank you in advance!

Re: [Wapt - installation path]

Published: April 26, 2016 - 11:00 AM
by sfonteneau
You need to modify your WAPT package to change this.

You can use this link for help:

https://wiki.mozilla.org/Installer:Comm ... _Arguments

Re: [Wapt - installation path]

Published: April 26, 2016 - 11:13 AM
by shirocen
I don't understand; the installation path should be chosen during the "wapt-get make-template *****.exe" command

from an .ini file in which the installation path is specified?

THANKS.

EDIT: I described the case for Firefox, but I have dozens of packages to install on D: (7zip, flash, etc.).

I successfully installed Firefox on D: using the command:

Code: Select all

firefox.exe /INI=c:\wapt\firefox.ini
Now, I would like to create a WAPT package for Firefox in which I can specify this .ini file or do anything else

manipulations that would allow me to install the software in D:.

THANKS.

Re: [Wapt - installation path]

Published: April 26, 2016 - 12:42 PM
by sfonteneau
Wapt is a command executor, so it cannot control the installation folder location of software.

The technique mentioned is only valid for Firefox. And this type of technique isn't available for all software.

Furthermore, it will require you to modify all the packages in your private repository.

This method will therefore be simpler for you:
http://www.clubic.com/forum/microsoft-w ... page1.html

But I don't necessarily recommend this method either.

Why do you want to move the software to D:\?

Simon

Re: [Wapt - installation path]

Published: April 27, 2016 - 10:44 AM
by shirocen
I install my software on D: to keep the system files separate on C: from the software on D:.

I finally found the solution: simply modify the installation command in the setup.py file and specify

an .ini file with the argument /INI=*****.ini:

run(r'firefox.exe /INI=c:\..\..\setup.ini')

Thank you for your help.

Re: [Wapt - installation path]

Published: May 13, 2016 - 10:49
by shirocen
Hello,

I regret to inform you that the method for installing on D: using an .ini file does not work.

Because the installation is performed on a remote machine, the client has no access to the .ini file hosted on the server

and is therefore unable to follow the instructions it contains.

I am therefore looking for a new method to install my software available on WAPT on the

D: drive of client machines.

Thank you.