Azure Stack update and publish custom vm items RRS feed

  • Question

  • Hi guys,

    is the azpg having issue or the default package is wrong?

    When the strings\resources.resjson, it came out error. but if rename as resources.json, it works fine.

    F:\Image.mcos\Azure Stack Marketplace Item Generator and Sample Templates\AzureGalleryPackageGenerator>.\AzureGallery.exe package -m "F:\Image.azs\Azure Stack Marketplace Item Generator and Sample Templates\Custom VMs\Test.Azure.W2K19.19.2.0\manifest.json" -o c:\temp
    Errors occurred during packaging of Gallery Item with manifest F:\Image.azs\Azure Stack Marketplace Item Generator and Sample Templates\Custom VMs\Test.Azure.W2K19.19.2.0\manifest.json
    After parsing a value an unexpected character was encountered: h. Path 'description', line 6, position 404.
       at Newtonsoft.Json.JsonTextReader.ParsePostValue()
       at Newtonsoft.Json.JsonTextReader.Read()
       at Newtonsoft.Json.Linq.JContainer.ReadContentFrom(JsonReader r, JsonLoadSettings settings)
       at Newtonsoft.Json.Linq.JContainer.ReadTokenFrom(JsonReader reader, JsonLoadSettings options)
       at Newtonsoft.Json.Linq.JObject.Load(JsonReader reader, JsonLoadSettings settings)
       at Microsoft.Azure.Gallery.Packaging.PackageWriter.ValidateResjsonFile(String filePath, IEnumerable`1 resourceKeys)
       at Microsoft.Azure.Gallery.Packaging.PackageWriter.SaveStringResources(Package package, String contentDirectory, IEnumerable`1 resourceKeys)
       at Microsoft.Azure.Gallery.Packaging.PackageWriter.CreatePackage(Manifest manifest, String manifestFileName, String contentDirectory, String outputLocation, String fullPath, Boolean ignoreValidation)
       at Microsoft.Azure.Gallery.Packaging.PackageWriter.TryCreatePackage(String manifestFile, String outputLocation, Boolean useSimpleValidation, String& packageFileName, String outputFile, IList`1& errors)

    also another question, how does the manifest knows which SKU to use? Because I got both W2K16 and W2K19, which share the same publisher and name. The VM image have been uploaded successfully and is reflected using get-azurermvmimagesku.

    PS C:\Windows\system32> Get-AzureRmVMImageSku -Location "eucentral1" -PublisherName "TSI" -Offer "TestWindowsServer"
    Skus         Offer             PublisherName Location   Id                                                                                                                                    
    ----         -----             ------------- --------   --                                                                                                                                    
    2016-TEST    TestWindowsServer TSI           eucentral1 /Subscriptions/XXX/Providers/Microsoft.Compute/Locations/eucentral1/Publishers/TSI/ArtifactTypes/V...
    2019-TEST    TestWindowsServer TSI           eucentral1 /Subscriptions/XXX/Providers/Microsoft.Compute/Locations/eucentral1/Publishers/TSI/ArtifactTypes/V...

    • Edited by danielkhor Monday, April 20, 2020 6:57 PM
    Monday, April 20, 2020 6:56 PM

All replies

  • Are you using the ASDK to upload these images? If so, what version? I am not aware of an issue with the AzureGallery.exe tool. 

    The marketplace items are linked to a template. The full info for the image should be in that template. 

    Tuesday, April 21, 2020 12:25 AM
  • it is before uploading when trying to generate the azpkg file. im doing this on my integrated Azure Stack, 1.2002.19.73. or should I just open a support ticket?

    Here is my manifest.json, follow everything according to the guide, but doesnt work.

    	"$schema": "https://gallery.azure.com/schemas/2015-10-01/manifest.json#",
    	"name": "TestWindowsServer",
    	"publisher": "TSI",
    	"version": "19.2.0",
        "displayName": "ms-resource:displayName",
        "publisherDisplayName": "ms-resource:publisherDisplayName",
        "publisherLegalName": "ms-resource:publisherDisplayName",
        "summary": "ms-resource:summary",
        "longSummary": "ms-resource:longSummary",
        "description": "ms-resource:description",
        "longDescription": "ms-resource:description",
    	"uiDefinition": {
    		"path": "UIDefinition.json"
        "links": [
            { "displayName": "ms-resource:documentationLink", "uri": "http://go.microsoft.com/fwlink/?LinkId=532898" }
        "artifacts": [
                "name": "2019-TEST",
                "type": "Template",
                "path": "DeploymentTemplates\\TESTW2K19.json",
                "isDefault": true
       "images": [{
    		"context": "ibiza",
    		"items": [{
    			"id": "small",
    			"path": "icons\\Small.png",
    			"type": "icon"
    			"id": "medium",
    			"path": "icons\\Medium.png",
    			"type": "icon"
    			"id": "large",
    			"path": "icons\\Large.png",
    			"type": "icon"
    			"id": "wide",
    			"path": "icons\\Wide.png",
    			"type": "icon"
    	"My Marketplace Items"

    Tuesday, April 21, 2020 2:24 AM
  • As this is with an Integrated Azure Stack and not an ASDK, you will need to create a support request. They will be able to properly test and reproduce the issue there. 
    Tuesday, April 21, 2020 9:44 PM