Limited Time Offer!

For Less Than the Cost of a Starbucks Coffee, Access All DevOpsSchool Videos on YouTube Unlimitedly.
Master DevOps, SRE, DevSecOps Skills!

Enroll Now

Working with uDeploy client using udclient and work with uDeploy command line

Step 1 – Install and setup JAVA including JAVA_HOME

$ sudo -s
$ yum install wget -y
$ wget -c --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-linux-x64.rpm
$ rpm -ivh jdk-8u131-linux-x64.rpm
$ java -version
$ export JAVA_HOME=/usr/java/jdk1.8.0_131

Step 2 – Click the link to download the Deploy Client zip. This zip contains the command line executable for use with IBM UrbanCode Deploy. such as https://52.66.112.139:8443/#tools

$ cd /opt/
$ mkdir cli
$ cd cli/
$ wget --no-check-certificate https://52.66.112.139:8443/tools/udclient.zip
$ unzip udclient.zip
$ cd udclient
[root@rajesh-udeploy-server udclient]# ./udclient
Global Args:
         -authtoken, --authtoken
            Optional. Can be set via the environment variable DS_AUTH_TOKEN. An
            authentication token generated by the server. Either an authtoken or
            a username and password is required
         -loggingConf, --loggingConf
            Optional. Can be set via the environment variable loggingConf. A
            properties file for custom log4j configuration. Overrides debug and
            debugHttp flags.
         -password, --password
            Optional. Can be set via the environment variable DS_PASSWORD. A
            password to authenticate with the server. Either an authtoken or a
            username and password is required
         -proxyHost, --proxyHost
            Optional. Can be set via the environment variable proxyHost. The
            hostname of a proxy (e.g., an agent relay) to use instead of
            directly connecting to the server
         -proxyPassword, --proxyPassword
            Optional. Can be set via the environment variable proxyPassword. A
            password to authenticate with the proxy.
         -proxyPort, --proxyPort
            Optional. Can be set via the environment variable proxyPort. The
            proxy port to use if a proxy hostname has been specified
         -proxyUser, --proxyUser
            Optional. Can be set via the environment variable proxyUser. A
            username to authenticate with the proxy.
         -username, --username
            Optional. Can be set via the environment variable DS_USERNAME. A
            username to authenticate with the server. Either an authtoken or a
            username and password is required
         -verifyServerIdentity, --verifyServerIdentity
            Optional. Can be set via the environment variable
            UC_TLS_VERIFY_CERTS. This option will only allow the command to
            complete if the server's certificate is trusted. (Default Value:
            false)
         -weburl, --weburl
            Required. Can be set via the environment variable DS_WEB_URL. The
            base URL of the IBM UrbanCode Deploy server. Eg.
            http://ibm-ucd.domain.com:8080

Global Flags:
         -t, --getTemplate
            Show the JSON template for the command instead of running the
            command. If a file argument is provided, the template will be output
            to that file.
         -h, --help
            Print the full description and help of the given command instead of
            running the command.
         -v, --verbose
            Print extra information during execution.
         --debug
            Print debugging information during execution. Implies verbose.
         --debugHttp
            Print detailed HTTP debugging information during execution.
Commands:
         Provide a web URL, username, and password to show all available commands.

Example Programs


$ ./udclient -weburl https://52.66.112.139:8443 -authtoken 815123a9-a76a-45a1-9c26-6a9411dd3ef5
$ ./udclient -weburl https://52.66.112.139:8443 -authtoken 815123a9-a76a-45a1-9c26-6a9411dd3ef5 createGroup -group group1 -authorizationRealm "Internal Security"
$ ./udclient -weburl https://52.66.112.139:8443 -authtoken 815123a9-a76a-45a1-9c26-6a9411dd3ef5 createUser newUser.json

vi newUser.json
--------------------------
{
  "name": "rajesh",
  "password": "password",
  "actualName": "Jane Smith",
  "email": "devops@rajeshkumar.xyz",
  "authenticationRealm": "Internal Security"
}

Reference
https://www.ibm.com/support/knowledgecenter/SS4GSP_6.2.4/com.ibm.udeploy.reference.doc/topics/cli_commands.html

Commands:

  addAgentPoolToTeam
  addAgentToPool
  addAgentToTeam
  addApplicationToTeam
  addComponentTemplateToTeam
  addComponentToApplication
  addComponentToTeam
  addEnvironmentBaseResource
  addEnvironmentProperty
  addEnvironmentToTeam
  addGroupToTeam
  addProcessToTeam
  addResourceToTeam
  addStatusToSnapshot
  addTagToAgent
  addTagToApplication
  addTagToComponent
  addTagToResource
  addUserToGroup
  addUserToTeam
  addVersionFiles
  addVersionLink
  addVersionStatus
  addVersionToSnapshot
  archiveVersion
  cancelWorkflow
  closeTask
  copyResource
  copyVersion
  createAgentPool
  createApplication
  createApplicationFromTemplate
  createApplicationProcess
  createAuthToken
  createBlueprintDesignerIntegration
  createComponent
  createComponentProcess
  createComponentTemplate
  createEnvironment
  createEnvironmentFromTemplate
  createGenericProcess
  createGroup
  createManyVersions
  createResource
  createResourceTemplate
  createSnapshot
  createSnapshotOfEnvironment
  createStatus
  createTeam
  createUser
  createVersion
  createZOSVersion
  deleteAgent
  deleteAgentPool
  deleteAgentProperty
  deleteAllDesiredInventoryVersions
  deleteBlueprintDesignerIntegration
  deleteComponentVersionPropDef
  deleteEnvironment
  deleteGroup
  deleteRedundantDesiredInventoryVersions
  deleteResource
  deleteResourceProperty
  deleteSnapshot
  deleteStatus
  deleteTeam
  deleteUser
  deleteVersion
  downloadVersionArtifacts
  exportDetailedGroup
  exportGroup
  forceRenameAgent
  getAgent
  getAgentPool
  getAgentPools
  getAgentProperty
  getAgentPrototypes
  getAgentStatuses
  getAgents
  getAllApplicationProcessesForApplication
  getAllTeams
  getAllUsersInRoleForTeam
  getAllUsersWithEmail
  getApplication
  getApplicationProcess
  getApplicationProcessExecution
  getApplicationProcessRequest
  getApplicationProcessRequestStatus
  getApplicationProcessUnfilledProperties
  getApplicationProperties
  getApplicationProperty
  getApplications
  getApplicationsProcessRequests
  getApplicationsProcessRequestsCount
  getApprovalTasks
  getBlueprintNodePropertiesTemplate
  getBlueprintsInApplication
  getComponent
  getComponentEnvironmentProperties
  getComponentProcess
  getComponentProcessRequest
  getComponentProcessRequestCount
  getComponentProcessRequests
  getComponentProperties
  getComponentProperty
  getComponentTemplates
  getComponentVersionPropDefs
  getComponentVersions
  getComponents
  getComponentsInApplication
  getEnvironment
  getEnvironmentBaseResources
  getEnvironmentProperties
  getEnvironmentProperty
  getEnvironmentsInApplication
  getFirstUserWithEmail
  getHighWatermarks
  getLatestSnapshotForEnvironment
  getOverlappingArtifacts
  getRelayStatuses
  getRelays
  getResource
  getResourceProperties
  getResourceProperty
  getResourceTemplate
  getResourceTemplateChildren
  getResources
  getResourcesWithComponentVersion
  getSnapshot
  getSnapshotConfiguration
  getSnapshotVersions
  getSnapshotsInApplication
  getStatus
  getStatusList
  getStatuses
  getSystemConfiguration
  getSystemProperties
  getSystemProperty
  getTagsOnAgent
  getTagsOnApplication
  getTagsOnComponent
  getTagsOnResource
  getTeam
  getUser
  getUserByEmail
  getVersionId
  getVersionLink
  getVersionLinks
  getVersionProperties
  importGroup
  importLdapUser
  importVersions
  installAgent
  listArtifacts
  lockSnapshotConfiguration
  lockSnapshotVersions
  login
  logout
  moveResource
  provisionEnvironment
  removeAgentFromPool
  removeAgentFromTeam
  removeAgentPoolFromTeam
  removeApplicationFromTeam
  removeComponentFromTeam
  removeComponentTemplateFromTeam
  removeEnvironmentBaseResource
  removeEnvironmentFromTeam
  removeEnvironmentProperty
  removeProcessFromTeam
  removeResourceFromTeam
  removeTagFromAgent
  removeTagFromApplication
  removeTagFromComponent
  removeTagFromResource
  removeUserFromGroup
  removeVersionFromSnapshot
  removeVersionLink
  removeVersionStatus
  repeatApplicationProcessRequest
  requestApplicationProcess
  restartAgent
  setAgentProperty
  setApplicationProperty
  setComponentEnvironmentProperty
  setComponentProperty
  setComponentVersionPropDef
  setEnvironmentProperty
  setResourceProperty
  setSystemConfiguration
  setSystemProperty
  setVersionProperty
  shutdownAgent
  testAgent
  updateResource
  updateResourceTemplate
  updateTeam
  updateUser
  upgradeAgent
Rajesh Kumar
Follow me