- Overview
- Get started
- Concepts
- Using UiPath CLI
- How-to guides
- Overview
- Pack and publish a solution
- Deploy to Orchestrator from CI
- Run tests in a pipeline
- Deploy an Agent
- Manage Orchestrator assets and queues
- Reuse existing Orchestrator resources
- CI/CD recipes
- Command reference
- Overview
- Exit codes
- Global options
- uip codedagent
- uip docsai
- add-test-data-entity
- add-test-data-queue
- add-test-data-variation
- analyze
- build
- create-project
- diff
- find-activities
- get-analyzer-rules
- get-default-activity-xaml
- get-errors
- get-manual-test-cases
- get-manual-test-steps
- get-versions
- get-workflow-example
- indicate-application
- indicate-element
- inspect-package
- install-data-fabric-entities
- install-or-update-packages
- list-data-fabric-entities
- list-workflow-examples
- pack
- restore
- run-file
- search-templates
- start-studio
- stop-execution
- uia
- uip traces
- Migration
- Reference & support
Reuse an existing Orchestrator connection, asset, or queue when deploying a Solution from a CI/CD pipeline, instead of provisioning a new one.
When you deploy a Solution, every resource it declares — queues, assets, processes, connections — is provisioned fresh in the deployment folder. Often you already have a shared resource in the target environment, such as a connection to an external system, and you want the deployment to reuse it instead of creating a new one.
In the Orchestrator UI you do this by choosing Customize when deploying and linking the resource by hand. That manual step does not translate to an unattended pipeline. The CLI equivalent is to fetch the deployment configuration, link the resource inside that file, then pass the file to deploy run.
config link binds one declared resource to an existing one. To make every resource reuse an existing counterpart instead, see Reuse every resource below.
Prerequisites
- A published solution package in the tenant. See Pack and publish a Solution.
- An External Application configured for client-credentials authentication, with these scopes:
AutomationSolutions,Solutions.Deployments,Solutions.Packages,OR.Folders,RCS.FolderAuthorization. See Authentication — Flow 2.OR.FoldersandRCS.FolderAuthorizationare required so the CLI can resolve and bind resources that live in Orchestrator folders. - The External Application assigned to the Orchestrator folder that holds the existing resource.
Steps
-
Authenticate with the External Application.
uip login \ --client-id env.UIPATH_CLIENT_ID \ --client-secret env.UIPATH_CLIENT_SECRET \ --tenant "$UIPATH_TENANT"uip login \ --client-id env.UIPATH_CLIENT_ID \ --client-secret env.UIPATH_CLIENT_SECRET \ --tenant "$UIPATH_TENANT" -
Download the deployment configuration for the package.
uip solution deploy config get "my-package" \ --package-version 1.0.0 \ -d ./deploy-config.jsonuip solution deploy config get "my-package" \ --package-version 1.0.0 \ -d ./deploy-config.json -
Link the solution resource to the existing Orchestrator resource. Use the resource name as it appears in the config file, and point
--folder-pathat the folder where the existing resource lives.uip solution deploy config link ./deploy-config.json "MyConnection" \ --name "SharedCrmConnection" \ --folder-path "Shared"uip solution deploy config link ./deploy-config.json "MyConnection" \ --name "SharedCrmConnection" \ --folder-path "Shared" -
Deploy the package with the edited configuration.
uip solution deploy run \ --name "my-deployment" \ --package-name "my-package" \ --package-version 1.0.0 \ --folder-name "MySolution" \ --parent-folder-path "Shared" \ --config-file ./deploy-config.jsonuip solution deploy run \ --name "my-deployment" \ --package-name "my-package" \ --package-version 1.0.0 \ --folder-name "MySolution" \ --parent-folder-path "Shared" \ --config-file ./deploy-config.json
The deployment reuses the linked resource and does not create a new one in the deployment folder.
On config link, --folder-path is where the existing resource lives. On deploy run, --parent-folder-path is where the deployment folder is created. They are separate flags on separate subcommands.
Connections: defer selection to runtime
For connection resources, linking an existing connection is not the only option. If you set the connection's authenticationType to ConfigurableByUsers in the deployment configuration, you can leave the connection unbound and defer its selection and authentication to execution time — users choose and authenticate the connection when the automation runs. This is also a valid configuration for activation.
authenticationType accepts two values: ConfigurableByUsers (defer to the user at runtime) and AuthenticateAfterDeployment (the connection must be authenticated after deployment). With AuthenticateAfterDeployment, if the connection is not authenticated by the time activation runs, the activation is reported as failed.
Reuse every resource
When you want the whole deployment to reuse existing resources rather than create new ones, set the conflict policy across all resources in one call before deploying.
-
Set the conflict policy on every resource in the configuration file.
uip solution deploy config set ./deploy-config.json --all conflictFixingAction UseExistinguip solution deploy config set ./deploy-config.json --all conflictFixingAction UseExisting -
Pass the same file to
deploy run --config-file, as shown in step 4.
See also
uip solution deploy— the reference forconfig get,config link,config set, anddeploy run.- Manage Orchestrator assets and queues — create the resources you later link to.
- Deploy to Orchestrator from CI — auth, caching, and version pinning for the pipeline this fits into.
- Authentication — the External Application flow used here.