We have several instances where we need to perform detection for if a system is 32-bit or 64-bit and install the appropriate 32/64-bit product. We found a great way to use conditions within a job to determine the cpu architecture using a script task containing the following line and using the return code to specify what to do:
IF %PROCESSOR_ARCHITECTURE% == x86 exit 86
This works great because we can set conditional statements that sends the 32-bit quick delivery task if the return value from above is 86, and if it's 0 then it sends the 64-bit task.
However, we need to find a method to publish this job and included logic to the software portal. To my knowledge, the only way is to bundle this logic into a single batch file within a software package and publish the software resourse, or to publish a managed software delivery policy with similar logic. There are issues we found with both:
ISSUES
1. Batch file within Software Package: The return codes are not maintained from the individual executions within the batch file. Only the last one is returned which could appear to be successful when actually a previous return code failed. We really don't want to have to design ellaborate scripts to evaluate each return code etc...
2. Managed Software Delivery: This works fine for the user, but this adds them to the policy and we don't want to give users the ability to add their system to a policy that will constantly check their systems for this software. We want this to be a one time only install.
Is there a solution (for sequential software installations) that would allow us to push the "job" manually as users call in, and also allow the users to pull the same "job"?
Thank you for your assistance!