Configure a Step to Execute an Object Storage Script

You can configure a user-defined step to execute a script that resides in Object Storage. The script type and format must comply with all the script type and format restrictions.

For a list of script type and format restrictions, see Limitations and Considerations.

Scripts that exit with a non-zero code are considered to have failed and will result in the user-defined step failing execution.

Note

A script stored in object storage is executed on the instance using the default ocarun user ID. You can not execute object storage scripts using a different user ID. Furthermore, you can not provide any additional arguments for object storage scripts. To execute scripts using a different user ID or to provide additional arguments to the script, see Configure a Step to Execute a Local Script.
  1. Select the Region in which the instance currently resides.
    Note

    When selecting the region for the instance, ensure that the instance is currently located in the selected region. Even if the step runs after the instance relocates to another region, the selected region must match the current region of the instance.
  2. Select the Run object storage script option.
  3. Select the Target instance. This is the instance on which you want to execute the script.
    Note

    If the Target instance is in a private subnet, ensure to set up a NAT Gateway. See Setting Up a NAT Gateway for more information.
  4. Select the Object storage bucket that contains the Script (the object storage object).
  5. Select the script that you want to execute.
  6. Click Add Step to finish adding the user-defined group and step.