-1

enter image description here

I'm using arcpy.UploadServiceDefinition_server() to publish SD files to a server that is federated with portal. Using this ESRI Documentaion I am able to publish the service to a specific folder on my server with the arguments in_folder_type="XXX", in_folder="xxx" Since my server is federated with portal those services are automatically shared with Portal which is what I want. However I would like like the services to appear in a specific folder as I did with server. I do not see a control to do this. Is this possible?


I attached an image of an example structure a service that is published to the server needs to be told to reside in a certain folder in portal. Not the root directory of portal.

  • a specific folder in portal? Like a group? – Maksim Nov 18 '15 at 16:49
  • No, a folder. X service hosted on server goes in y folder in portal..The visibility of Y folder is managed though groups and user controls within Portal. – risail Nov 18 '15 at 16:52
  • 1
    Do you have 10.3? Take a look at the MXD to WebMap tool. We implemented folder that does what you want there (you can look at the tool code). Without digging in, I'm pretty sure you'll need to manually move the item after publishing it (like we did)... – KHibma Nov 18 '15 at 17:35
  • While I did not know about MXDToWebMap_server that tool is for maps, my question is service specific. And yes I have 10.3.1 – risail Nov 18 '15 at 17:39
  • 2
    The tool makes SDs, uploads them, and turns them into a featureservice to build the map off of. Regardless, I 99% sure that UploadService tool only uses Folder in the context of server, not Portal. Looking at the REST API, theres no "folder" on addItem, so you'll need to call MoveItem after you've upload your SD. – KHibma Nov 18 '15 at 17:43
0

As commented by @KHibma:

Take a look at the MXD to WebMap tool. We implemented folder that does what you want there (you can look at the tool code). Without digging in, I'm pretty sure you'll need to manually move the item after publishing it (like we did)...


The tool makes SDs, uploads them, and turns them into a featureservice to build the map off of. Regardless, I 99% sure that UploadService tool only uses Folder in the context of server, not Portal. Looking at the REST API, theres no "folder" on addItem, so you'll need to call MoveItem after you've upload your SD.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.