TFS 2017 silent installation using Powershell - powershell

I am trying to install TSF 2017 by using silent installation powershell script. I am able to install it but its not installing properly. And its not creating any folders in program files. But its showing in control panel.
Below is the script which I am using now,
$Installer="D:\TeamFoundationServer2017_Update2\TfsServer2017.2.exe"
$Params=#("D:\TeamFoundationServer2017_Update2\ISO\tfsserver2017.2_enu.iso","/Q","/Full","/NoRestart","/NoWeb","/Passive","/ProductKey","/Layout=C:\Users\ul\Desktop\Test","/NoRefresh","/Log=Desktop\Logfile.txt")
& $Installer $Params
Is there anything I am missing out in $Params. Its calling exe file and executing it. In contorl panel I can able to see. But in program files its not coming. And its not installing also.
Please help me in this.

TfsServer2017.2.exe is a web installer, it will download TFS from VisualStudio.com and kick off the installation. However, the installation process itself simply gets TFS bits onto your machine. At the end of this process, the installer will launch the TFS Configuration Center.
Even select Basic scenario(This scenario is optimized for simplicity, using default options for most inputs), you will still need to choose and enter many configuration.
More details please refer: How to set up TFS on a single server
Besides, this is only suitable for a single server scenario, you could also install TFS under Dual server/ Multiple server configuration . Highly doubt this could be done through a single powershell script.
You could also have a look at this tutorial -- Team Foundation Server 2017 Installation Guide
If you just want to want to use PowerShell DSC resources to install configure a TFS build agent, please refer this code source in GitHub.

Related

VSTO: General Install Error Windows 10

We have a VSTO Application that is installed on many machines. If the Add-In is already installed, there is no issue. If you try to uninstall or install, you get the following error message:
The following Microsoft Office solution cannot be installed due to a general installer error: App_Name.vsto
0x80070002
This application has been working without hiccups for almost a year now. Our Sys Admin and I believe we've narrowed it down to a mandatory Windows 10 update as our base Windows 10 image has it working fine and it works on Windows 7 no issue. However, the update is already pushed out and nothing is showing up in the logs.
I know the VSTOInstaller.exe.Config file has been the cause for several of these installer issues, however I cannot find that file on any of our machines even though I KNOW I modified one machine and changed the name to VSTOInstaller.exe.Config.Old for the Business.fba error some have gotten. I assume an update somehow packaged the config file into the .exe.
The Windows 7 machines also don't have the Config file as well...
What we've tried:
Searching for an older .Config file to place in the folder
Rolling back to a previous version
Recompiling
Changing the publish destination folder and setting version back to version 1.0.0.0
Update: Placing a VSTOInstaller.Exe.Config then a VSTOInstaller.Config in the C:\Program Files\Common Files\microsoft shared\VSTO\10.0 folder
Update: Running repair then doing an uninstall/reinstall on Visual Studio Tools for Office Runtime (x64) program from Control Panel.
Update: Cleared Application Event Log
Update: Stopped Windows Update service, Renamed C:\Windows\SoftwareDistribution folder to C:\Windows\SoftwareDistributionOld, then restarted the Windows Update service.
I'm at a loss. Any help is GREATLY appreciated.
If anyone has the VSTOInstaller.exe.Config file, I'd love to try and place that in the folder to see if it works.
Version:
Word Version - 16.0.6769.2040
VS Version - 14.0.25420.1
OS Version - 1511 (OS Build 10586.494)
Turns out the error was part of a Microsoft Office update. Unsure if somehow the update listed in the question updated Office 2016 in the background somewhere.
The steps to resolution were as follows:
Uninstall O365 from the Control Panel
Download the a full removal tool and run it from https://support.office.com/en-us/article/Uninstall-Office-2016-Office-2013-or-Office-365-from-a-PC-9dd49b83-264a-477a-8fcc-2fdf5dbf61d8
At this point after those have ran, uninstall the add-in if it was installed.
Reinstall O365
Reinstall/Install the VSTO Add-In
Easier resolution than I thought and really appreciate all the assistance.
Windows 10 Update error 0x80070002 or 0x80070003
Step 1: Windows Service Checklist:
Open Windows services.msc, check the following services status (If it is different set it to the recommended settings)
[enter image description here][1]
Disable any third party antivirus applications, as it may block the Windows 10 upgrade process.
Step 2: Reset Windows updates:
Resetting windows updates, in this step we will clean up old failed updates that have been saved in the computer, let start by first disabling the windows update service.
Service Status(Start/Stop/Blank) Automatic/manual/Disabled
Background Intelligent file Transfer Started Automatic
Crytographic Service Started Automatic
DCOM service Started Automatic
RPC Started Automatic
Windows Modules Installer Started Automatic
Windows Update Started Automatic
Windows defender Blank Disabled
Windows firewall Blank Disabled
Disable Windows update service and stop the service
Now open Run command and type %windir%
Check for Software distribution folder delete the folder. (If it fails restart the computer, then try deleting it)
In Run command window type “cleanmgr” to launch disc cleanup to clean old junk files.
Restart the windows update service set it Automatic. Once completed, the windows upgrade error code 80070002 should be resolved. Try the upgrade now. Still unlucky, get in touch with us or proceed to next step
Step 3: Dism/Readiness Tool
This step is to fix core Operating system files that are corrupted and is affecting the Windows 10 upgrade and causing the error. Most of the cases running the tool or the command will fix the corrupted files, there are cases where some stubborn files remain. We can assist you in repairing them manually, post the log to us so we can check and revert back to you.
Depending on the OS, you have to choose proper tools,
For Windows 8 and higher use the following command in elevated command prompt.
Dism /Online /Cleanup-Image /ScanHealth
For windows 7: Download and run windows update readiness tool
microsoft.com/en-in/download/details.aspx?id=20858 –X64
microsoft.com/en-in/download/details.aspx?id=3132 – X86
Check the logs for the above tools in the following location
%windir%/logs/cbs
Post the log for further steps.
Please refer to this link for more info :
http://www.msofficelivesupport.com/windows-update/windows-10-update-error-0x80070002-or-0x80070003/

Nuget Command-line install is not launching Install/Init scripts

I was trying to use Nuget as a software deployment system (repository, versioning and delivery) - idea from Octopus. Previously I was packaging ASP.NET sites into a self-extracting RAR archives with a .CMD startup scripts embeded. Now I'm trying to use Nuget creating puckages during automated build. The issue is that the package installation scripts (tools\Install.ps1 or tools\Init.ps1) do not execute if the package is being installed using command line:
nuget.exe install <package_id> -OutputDirectory <install_folder> -source <local_repo>
Same scripts are able to execute when package installed from Visual Studio Package Manager or Console.
I do not see why this shouldn't be possible given omnipresence of PowerShell.
Am I missing something or this is behaviour by design? Will appreciate you help.
Yes, we did consider MSDeploy but we already have install scripts that do the same thing and give more control and we need some strong package management and repository for build artifacts (something that Java folks do with Maven).
As of today, the powershell scripts are not invoked from doing installations from command line.
One reason for this is that, in general, most of the install/init actions are tied to dte and the visual studio project and doesn't add much value to be able to run it from outside VS.
We have a backlog item for enabling support for exe based scripts too in addition to powershell.

Recommended approach to deploy VMware PowerCLI command line console application

PowerCLI with .NET has some dependencies on dll's that you get only when you install PowerCLI on each machine you want to run.
I have a console app with command line arguments, which when deployed using the usual method doesn't work because of the unmet dependencies...these assemblies are part of the GAC.
Clickonce deployment proved to be useless..it didnt recognize my arguments although I passed them as query params.
Finally, I installed VMware PowerCLI on this remote machine. Then ran the .exe and it worked. Is there a way to avoid installing PowerCLI and be able to include all the dependencies with my exe during deployment?
Depending on where exactly you want to deploy your console application, you may be out of luck. According to this page and the most relevant forum post I could find, the PowerCLI assemblies are not redistributable. Your best bet if you want to distribute this application outside your company is to use the Web Services SDK - a huge pain since you've already developed the app.
Assuming your application is for internal use only and you just want to deploy it on its destination server, you can do the following to reference the assemblies locally:
On the development machine, copy whichever PowerCLI .dlls you reference from the GAC (in %WINDIR%\assembly) to your solutions local directory.
Change your references in the project to point to the local versions of the .dlls.
Open the 'Properties' view for each of the references, and make sure 'Copy Local' is set to True.
Compile and deploy your console application (and it's coresident .dlls) to the target machine, it should reference them in the local directory and run without external dependencies.
Hope that helps!
You could also automate PowerCLI installation with a silent installation one-line Powershell script, if the problem is hiding the installation from the users.
Invoke-Expression ("cmd /c '$powerCLIexeFilePath'/S /VADDLOCAL=ALL /V/qn")

Correct deployment tool to copy files & run SQL Script

What would be the best way to deploy upgrades to a piece of software with the following requirements:
The upgrade:
Must be run from a client machine, not a server.
Must Show a dialog to select a network location and copy files to a share.
Must show a dialog to enter SQL Server connection information and the upgrade must connect to SQL Server to run an upgrade script.
Must not change anything on the client machine from which the upgrade is run. (Nothing in Add/Remove programs, registry, etc. I.e. no Windows Installer.)
Must not rely on any additional dlls or frameworks. The user must be able to download a single file and run it from Windows XP SP2 without having to install anything else.
Some things I have looked into:
Batch files (can’t show a dialog to allow the user to enter connection information)
OSQL (can’t show a dialog and can’t copy files)
WiX (runs on top of Windows Installer so it puts things on the client machine from which it is run)
Custom C#/VB app (requires .NET framework)
Winzip/WinRAR (can't show a dialog, can’t run SQL Scripts)
If you don't want to rely on any dlls and frameworks, you should make a native app, this can be, for example, custom winrar sfx (you can run additional scripts after extraction, this can be a batch that executes sqlcmd).

Packaging application

We have a windows app and we were using Wise for deployment. Recently we switched to InstallAware and though it has some good points we are facing some issues. Can someone recommend another deployment and packaging app? We are a small company and we do not have a dedicated staff for packaging etc. Also our package includes SQL server express installation and we would love to have the simplicity of such includes as is in IA.
How about NSIS or InnoSetup? They're both widely used, and not that hard to use. (If you choose InnoSetup, also download ISTool, it's a lot easier than writing the script file manually.)
We've used NSIS several times, both for full regular desktop installers, and for small, silently installing patches. It's easy to write a basic installer, especially if you use HM NIS Edit which acts as a wizard and IDE for NSIS. Because it's scriptable, you'll be able to check if SQL Server Express is already installed - if not, it can be installed as part of your installer process.
I have never used anything but Windows Setup and the setup projects that come with Visual Studio. Do you have any unusual requirements that prevent you from doing that?
I assume your requirement as follows,
You are using wise package studio to create\customize the application to create MSI and these msi package will be deployed or installed to your environment.
My question is : How many desktops \laptops are their in your company (Infrastructure)
Solution to your question based on my assumption:
At present Admistudio is the best product to replace the Wise and you can use Installshield repackager to create or customize the applications.
Install anyware is used to customize the Dll files (Build and release method) and create custom actions in that build file and build it to MSI
Installshield Repackager is used to create MSI from Exe files and also customize existing MSI using transform file (no need to modify existing MSI instead we can create MST file to MSI and perform the customization to MST file and same file will be applied while deployment.)
Please let me know if you need further assistance.