Category filter
Script to deploy MSIX packages on Windows
In this doc, you will be learning how to deploy MSIX packages using scripts.
MSIX is a Windows app package format that provides a modern packaging experience for all kinds of Windows apps. Introduced by Microsoft, MSIX is a single package format that can be used across all Windows platforms, including Windows 10, Windows 11, Windows Server, and the Xbox One family of devices. It offers versatile support for various types of applications, including Win32, WPF, and UWP apps, making it a universal packaging solution for all Windows applications.
MSIX apps provide a streamlined installation and uninstallation process, ensuring that no residual files are left behind. These apps operate within a containerized environment, running in isolation from the rest of the system. This isolation helps prevent conflicts between applications and guarantees smooth operation for each app without impacting others. Here’s a script to deploy MSIX packages on Windows devices. IT administrators can use Hexnode’s “Execute Custom Script” action to execute it.
PowerShell script to install MSIX app
1 |
DISM /Online /Add-ProvisionedAppxPackage /PackagePath:"<path_of_the_MSIX_app>" /SkipLicense |
The provided script contains a single command that uses the DISM tool to deploy a provisioned app package (.msix) on Windows devices. The command begins with “DISM (Deployment Image Servicing and Management)”, which is a built-in Windows tool used to manage various aspects of Windows images, including adding, removing, and configuring applications.
The “/Online” argument directs DISM to perform the operation on the currently running Windows operating system (online servicing) rather than on an offline image file.
The “/Add-ProvisionedAppxPackage” specifies the action to execute, which in this case is to add a new provisioned application package. The “/PackagePath:” argument indicates the location of the .msix app package to be installed. Replace “<path_of_the_MSIX_app>” with the actual file path on the system.
Lastly, the optional “/SkipLicense” argument instructs DISM to bypass any license agreement prompts that might appear during the installation process on the device end.
What happens at the device end?
Upon the successful execution of the script, the MSIX application will be silently installed on the Windows device.