Updated on 2024-04-18 GMT+08:00

Using SWR Public Images

Prerequisites

You have created an image and pushed it to SWR.

Procedure

  1. Images in SWR cannot be pulled during building. Therefore, you need to set the image type to Public.

    1. Log in to SWR.
    2. In the navigation pane, choose My Images, click the image name to go to the image details page, and click Edit in the upper right corner.
    3. In the dialog box, set the type to be public.

    4. To obtain the complete image path, click to copy the image download command. The part following docker pull is the image path.

  2. Add Use SWR Public Image, when configuring build actions.
  3. Paste the image address obtained in step 1 to the text box.

    When pasting the download command to the image address text box, delete docker pull.

  4. Enter the build commands in the command window and run the build task commands to complete the build.

    For example, if the image is used for a Maven build, configure commands for building with Maven. For an npm build, configure commands for building with npm. This rule also applies to other builds.