Running a Robocorp Cloud process on a local machine with Robocorp App

Robocorp Cloud allows you to manage, orchestrate, and schedule the execution of your software robots in a central place. Robocorp Cloud has Processes, which contain steps that Runtime Environments execute. A Runtime Environment can be a Docker container, or an actual physical or virtual machine running the Robocorp App application.

In this article, we will see how to set up a Robocorp Cloud process to run on a local machine via Robocorp App.

To follow along, you will need a Robocorp Cloud account and Robocorp App, available for Windows, Mac, and Linux. If you haven't already, you might want to follow the Quickstart guide to get familiar with Robocorp Cloud first.

Follow the Robocorp App installation guide, to install and link Robocorp App to your workspace in Robocorp Cloud. Make sure your Robocorp App is correctly linked and running:

Robocorp Cloud- Runtime Environment running

In the Environments page of your workspace in Robocorp Cloud you should now see your Robocorp App, marked as Idle:

Robocorp Cloud - Runtime Environment idle

With the Robocorp App set up and running, we are ready to assign it something to do!

Modify the "Robocorp Cloud Example Process" to run locally via Robocorp App

All new Robocorp Cloud accounts contain an example process which downloads a picture from Google Search Images. The process has one robot, which is configured by default to run via a Robocorp hosted container in the cloud.

You can find more details about the example process and instructions on how to run it in the Quickstart guide.

Let's modify the example process so that it runs via our locally running Robocorp App instead!

  1. Find the Robocorp Cloud Example Process in the Processes page in Robocorp Cloud, and click on it to configure it: Clicking on the example process
  2. Click on the Google Image Search in the Steps section of the page to configure it: Clicking on the robot inside the example process
  3. On the robot configuration page, find the Environment section. You can see that the robot is currently set to be run by the robocorp/robocontainer:latest Runtime Environment. Click on the trash can icon (Detach Environment) to detach the current runtime environment. Then, click on the + icon (Attach environment) to attach a new runtime environment, and select your runtime environment from the list: Detaching robocorp/robocontainer:latest Runtime Environment, attaching local runtime environment

And we are done!

Start the process

With these configuration changes, we are now ready to execute the process locally.

Make sure your Robocorp App is running, go back to the Processes page in Robocorp Cloud, and start the Robocorp Cloud Example Process by clicking on the Start button.

This will tell the runtime environment to execute the process locally: in our case, it will open a local browser, do a search, and download a picture. It will then upload any artifacts to the cloud (log files, and in our case, the cat picture). The execution will show a log of the executed operations in the Console Output window.

Running example process in Robocorp App

The first execution will be slower than shown here because the Robocorp App has to set up the environment for you. Environments are cached and reused so that the successive executions will be much faster.

Summary

By installing and running Robocorp App in a target system, you can run your robots there. Robots are triggered and scheduled in Robocorp Cloud, and artifacts and logs are uploaded back to Robocorp Cloud.