In ArcGIS Pro, one can easily create an SD file to eventualy publish a web layer (service) on a federated server using Share - Web Layer - Publish Web Layer - Save As SD.
With this SD file, it's simple to automate services publishing process on different environments (dev, staging, prod).
However, when it comes to overwrite a service (Share - Web Layer - Overwrite Web Layer), there's no "Save As SD" to create this file. There's only a "Publish" function.
Please add this option to create the SD file when someone wants to overwrite a service.
I know of some Python code can be done to try to do this:
But it seems obvious that extended properties are really difficult to manage (ex : WMS, etc).
Moreover, we found a way to get the sd file when an overwrite is manually done with ArcGIS Pro :
1. Overwrite Web Layer - Publish
2. A series of files are created here including .sddraft : C:\Users\%username%\AppData\Local\ESRI\ArcGISPro\Staging\SharingProcesses\%jobnumber%
3. Use Stage Service geoprocessing tool to create the sd file from sddraft
4. Publish to dev, staging and prod from this sd file and ArcGIS API for Python (publish_sd). We use Azure DevOps Pipelines for this, adding SD files in our repository.
5. Everything works perfectly, even Portal itemId is preserved!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.