Building custom images

You can build custom images based on Jupyter notebooks and RStudio runtime images available in IBM Watson Studio. The images contain pre-selected open-source, as well as selected IBM libraries. Building custom images enables you to optimize the standard software configuration of a runtime for your application needs. Custom images can also be used in air-gapped environments with requirements which forbid exposing any operations to the internet.

To create a custom image, you need to download the image of the runtime that you want to customize, build a new custom image by adding libraries to the image you downloaded, register the new image, and finally update the environment template you created in your project to use the new custom image.

You can also build custom images based on the SPSS Modeler runtime images to install custom ODBC drivers. Follow the instructions under Building custom images to install ODBC drivers instead of the instructions here.

Creating and registering a custom image

Required role: You must be a Cloud Pak for Data cluster administrator to create and register a custom image.

Follow these steps to create and register a custom image:

  1. Prepare to build a new image by:

    1. Getting the registry URL to use for Docker commands and in scripts. The Watson Studio runtime images are stored in a Docker image registry. In Cloud Pak for Data, you can only use an external registry outside of the Cloud Pak for Data OpenShift cluster.

      To use that registry, you need the URL to the external registry that was used during the installation of Cloud Pak for Data. You use the same URL for all commands and in all scripts that you run.

    2. Downloading the configuration file for the runtime image that you want to customize. See Downloading the configuration file.
    3. Downloading the image in the configuration. See Downloading the image.
  2. Adding customizations and building a new image. See Creating a custom image.
  3. Pushing the image to the container server. See Registering the custom image.
  4. Changing and uploading the configuration file. See Uploading the changed configuration.

Using the image in projects

After the custom image was created and registered, it can be selected in IBM Watson Studio to run notebooks or to launch RStudio. To do this, you need to create an environment template that uses the custom image and then select this environment template to run your notebook or launch RStudio.

Required role: You need Admin or Editor permissions on the analytics project to create an environment template and select the custom image.

Following these steps to create an environment template.

Considerations

If you use custom runtime images, you must consider the following aspects:

Parent topic: Customizing environments