|
| 1 | +--- |
| 2 | +title: MSIXMGR tool parameters - Azure Virtual Desktop |
| 3 | +description: This article contains the command line syntax to help you understand and get the most from the MSIXMGR tool. In this article, we'll show you the syntax of all the parameters used by the MSIXMGR tool. |
| 4 | +author: fiza-microsoft |
| 5 | +ms.author: fizaazmi |
| 6 | +ms.topic: concept-article |
| 7 | +ms.date: 04/04/2023 |
| 8 | +--- |
| 9 | + |
| 10 | +# MSIXMGR tool parameters |
| 11 | + |
| 12 | +This article contains the command line syntax to help you understand and get the most from the MSIXMGR tool. In this article, we'll show you the syntax of all the parameters used by the MSIXMGR tool. |
| 13 | + |
| 14 | +## Prerequisites: |
| 15 | + |
| 16 | +Before you can follow the instructions in this article, you'll need to do the following things: |
| 17 | + |
| 18 | +- [Download the MSIXMGR tool](https://aka.ms/msixmgr) |
| 19 | +- Get an MSIX-packaged application (.MSIX file) |
| 20 | +- Get administrative permissions on the machine where you'll create the MSIX image |
| 21 | +- [Set up MSIXMGR tool](/azure/virtual-desktop/app-attach-msixmgr) |
| 22 | + |
| 23 | +## Parameters |
| 24 | + |
| 25 | +### -AddPackage or -p |
| 26 | + |
| 27 | +Add the package at specified file path. |
| 28 | + |
| 29 | +``` |
| 30 | +-AddPackage [Path to the MSIX package] |
| 31 | +``` |
| 32 | + |
| 33 | +#### Example |
| 34 | + |
| 35 | +``` |
| 36 | +msixmgr.exe -AddPackage "C:\SomeDirectory\myapp.msix" |
| 37 | +``` |
| 38 | + |
| 39 | +### -RemovePackage or -x |
| 40 | + |
| 41 | +Remove the package with specified package full name. |
| 42 | + |
| 43 | +``` |
| 44 | +-RemovePackage [Package name] |
| 45 | +``` |
| 46 | + |
| 47 | +#### Example |
| 48 | + |
| 49 | +``` |
| 50 | +msixmgr.exe -RemovePackage myapp_0.0.0.1_x64__8wekyb3d8bbwe |
| 51 | +``` |
| 52 | + |
| 53 | +### -FindPackage |
| 54 | + |
| 55 | +Find a package with specific package full name. |
| 56 | + |
| 57 | +``` |
| 58 | +-FindPackage [Package name] |
| 59 | +``` |
| 60 | + |
| 61 | +#### Example |
| 62 | + |
| 63 | +``` |
| 64 | +msixmgr.exe -FindPackage myapp_0.0.0.1_x64__8wekyb3d8bbwe |
| 65 | +``` |
| 66 | + |
| 67 | +### -ApplyACLs |
| 68 | + |
| 69 | +Applies ACLs to a package folder (an unpacked package). |
| 70 | + |
| 71 | +``` |
| 72 | +-ApplyACLs -packagePath [Path to the package folder] |
| 73 | +``` |
| 74 | + |
| 75 | +#### Example: |
| 76 | + |
| 77 | +``` |
| 78 | +msixmgr.exe -ApplyACLs -packagePath "C:\SomeDirectory\name_version_arch_pub" |
| 79 | +``` |
| 80 | + |
| 81 | +### -MountImage |
| 82 | + |
| 83 | +Mounts the VHD, VHDX, or CIM image. |
| 84 | + |
| 85 | +``` |
| 86 | +-MountImage -imagePath [Path to the MSIX image] -fileType [VHD | VHDX | CIM] |
| 87 | +``` |
| 88 | + |
| 89 | +#### Example |
| 90 | + |
| 91 | +``` |
| 92 | +msixmgr.exe -MountImage -imagePath "C:\SomeDirectory\myapp.cim" -fileType CIM |
| 93 | +``` |
| 94 | + |
| 95 | +|Optional parameters|Description|Example| |
| 96 | +| -------- | -------- | -------- | |
| 97 | +|-readOnly|Boolean (true of false) indicating whether the image should be mounted as read only. If not specified, the image is mounted as read-only by default. |`msixmgr.exe -MountImage -imagePath "C:\SomeDirectory\myapp.cim" -filetype CIM -readOnly false`| |
| 98 | + |
| 99 | +### -quietUX |
| 100 | + |
| 101 | +Quiet mode, no user interaction. Use in conjunction with other parameters. |
| 102 | + |
| 103 | +``` |
| 104 | +-quietUX |
| 105 | +``` |
| 106 | + |
| 107 | +#### Example |
| 108 | + |
| 109 | +``` |
| 110 | +msixmgr.exe -AddPackage "C:\SomeDirectory\myapp.msix" -quietUX |
| 111 | +``` |
| 112 | + |
| 113 | +### -UnmountImage |
| 114 | + |
| 115 | +Unmounts the VHD, VHDX, or CIM image. |
| 116 | + |
| 117 | +``` |
| 118 | +-UnmountImage -imagePath [Path to the MSIX image] -fileType [VHD | VHDX | CIM] |
| 119 | +``` |
| 120 | + |
| 121 | +#### Example: |
| 122 | + |
| 123 | +``` |
| 124 | +msixmgr.exe -UnmountImage -imagePath "C:\SomeDirectory\myapp.vhdx" -fileType VHDX |
| 125 | +``` |
| 126 | + |
| 127 | +|Optional parameters|Description|Example| |
| 128 | +| -------- | -------- | -------- | |
| 129 | +|-volumeId|Specifies GUID (specified without curly braces) associated with image to unmount. This is an optional parameter only for CIM files. |`msixmgr.exe -UnmountImage -volumeId 0ea000fe-0021-465a-887b-6dc94f15e86e -filetype CIM`| |
| 130 | + |
| 131 | +### -Unpack |
| 132 | + |
| 133 | +Unpacks package (`.appx`, `.msix`, `.appxbundle`, `.msixbundle`) and extract its contents to a folder. |
| 134 | + |
| 135 | +``` |
| 136 | +-Unpack -packagePath [Path to package to unpack OR path to a directory containing multiple packages to unpack] -destination [Directory to place the resulting package folder(s) in] |
| 137 | +``` |
| 138 | + |
| 139 | +> [!NOTE] |
| 140 | +> If you're using VHD or VHDX, we recommend the size is four times the size of MSIX package. |
| 141 | +
|
| 142 | +#### Example |
| 143 | + |
| 144 | +``` |
| 145 | +msixmgr.exe -Unpack -packagePath "C:\SomeDirectory\myapp.msix" -destination "C:\Apps\myapp" |
| 146 | +``` |
| 147 | + |
| 148 | +|Optional parameters|Description|Example| |
| 149 | +| -------- | -------- | -------- | |
| 150 | +|-applyacls|Applies ACLs to the resulting package folder(s) and their parent folder. |`msixmgr.exe -Unpack -packagePath "C:\SomeDirectory\myapp.msix" -destination "C:\Apps\myapp" -applyACLs` | |
| 151 | +|-create|Creates a new image with the specified -filetype and unpacks the packages to that image. |`msixmgr.exe -Unpack -packagePath "C:\SomeDirectory\myapp.msix" -destination "C:\Apps\myapp" -applyACLs -create -fileType VHDX -vhdSize 200` | |
| 152 | +|-fileType|The type of file to unpack packages to. Valid file types include `VHD`, `VHDX`, `CIM`. This is a required parameter when unpacking to CIM files. |`msixmgr.exe -Unpack -packagePath "C:\SomeDirectory\myapp.msix" -destination "C:\Apps\myapp" -applyACLs -create -fileType CIM -rootDirectory apps` | |
| 153 | +|-rootDirectory|Specifies root directory on image to unpack packages to. Required parameter for unpacking to new and existing CIM files. |`msixmgr.exe -Unpack -packagePath "C:\SomeDirectory\myapp.msix" -destination "C:\Apps\myapp" -applyACLs -create -filetype CIM -rootDirectory apps` | |
| 154 | +|-validateSignature|Validates a package's signature file before unpacking package. This parameter will require that the package's certificate is installed on the machine.<br /><br />For more information, see [Certificate Stores](/windows-hardware/drivers/install/certificate-stores).|`msixmgr.exe -Unpack -packagePath "C:\SomeDirectory\myapp.msix" -destination "C:\Apps\Myapp" -validateSignature -applyACLs`| |
| 155 | + |
| 156 | +### -? |
| 157 | + |
| 158 | +Display help text at the command prompt. |
| 159 | + |
| 160 | +#### Example: |
| 161 | + |
| 162 | +``` |
| 163 | +msixmgr.exe -? |
| 164 | +``` |
| 165 | + |
| 166 | +## Next steps |
| 167 | + |
| 168 | +To learn more about MSIX app attach, check out these articles: |
| 169 | + |
| 170 | +- [What is MSIX app attach?](/azure/virtual-desktop/what-is-app-attach) |
| 171 | +- [Set up MSIX app attach with the Azure portal](/azure/virtual-desktop/app-attach-azure-portal) |
| 172 | +- [Set up MSIX app attach using PowerShell](/azure/virtual-desktop/app-attach-powershell) |
| 173 | +- [Create PowerShell scripts for MSIX app attach](/azure/virtual-desktop/app-attach) |
| 174 | +- [Prepare an MSIX image for Azure Virtual Desktop](/azure/virtual-desktop/app-attach-image-prep) |
| 175 | +- [Set up a file share for MSIX app attach](/azure/virtual-desktop/app-attach-file-share) |
| 176 | + |
| 177 | +If you have questions about MSIX app attach, see our [App attach FAQ](/azure/virtual-desktop/app-attach-faq) and [App attach glossary](/azure/virtual-desktop/app-attach-glossary). |
0 commit comments