Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Install EXE - executable.exe is missing (2.12.0) #1541

Closed
LMS235 opened this issue Jul 18, 2023 · 3 comments · Fixed by #1542
Closed

[BUG] Install EXE - executable.exe is missing (2.12.0) #1541

LMS235 opened this issue Jul 18, 2023 · 3 comments · Fixed by #1542

Comments

@LMS235
Copy link
Contributor

LMS235 commented Jul 18, 2023

OCS Inventory version
Version : 2.12.0

Describe the bug
In 2.11.1 build a normal EXE: NAME="executable.exe /S /user=all"
In 2.12.0 build a normal EXE: NAME="/S /user=all" => "executable.exe" is missing => deployment won't work

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'Deployment' => 'Build'
  2. Click on 'Windows' => 'Install / Uninstall' => 'Execute an exe'
  3. Create an EXE Install and see the info file....

Expected behavior
As of now, the whole deployment feature in 2.12.0 is not really functional (see also #1536). This must change as soon as possible!

@LMS235
Copy link
Contributor Author

LMS235 commented Jul 18, 2023

the error is in the adjustments in the file ~/ocsreports/require/teledeploy/PackageBuilder.php

fastest solution as workaround is to use the "old" file (PackageBuilder.php) from 2.11.1, then at least the deployment of Windows works clean again (EXE and CUSTOM EXE - #1536)

something between line 400 and 409 is wrong:

		if ($xmlDetails->packagedefinition->ACT  == 'LAUNCH' && $xmlDetails->formoption->ISCUSTOM == false) {
			// if pkg built from linux bashscript option and not custom package, 
			// default retrieved if a command but w/ LAUNCH, the agent will be expecting a name
			$name = substr($xmlDetails->packagedefinition->COMMAND, strpos($xmlDetails->packagedefinition->COMMAND, ' ') + 1);
			$info .= "NAME=\"" . $name . "\" ";

		} else if ($xmlDetails->packagedefinition->ACT  == 'LAUNCH') {
            $info .= "NAME=\"" . $xmlDetails->packagedefinition->COMMAND . "\" ";
        }

@charleneauger charleneauger linked a pull request Jul 18, 2023 that will close this issue
@charleneauger
Copy link
Member

Hi @LMS235 ,

I made some fixes related to your issues.
You will find them in the following PR : #1542

Best regards,
Charlene

@LMS235
Copy link
Contributor Author

LMS235 commented Jul 19, 2023

tested --> work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants