This topic describes how to mount an Object Storage Service (OSS) bucket to an Alibaba Cloud Container Service for Kubernetes (ACK) cluster. Deep Learning Containers (DLC) allows you to store source data in OSS.

Step 1: Create an OSS bucket

  1. For more information about how to activate OSS, see Activate OSS.
  2. For more information about how to create an OSS bucket, see Create buckets.
    Note The OSS bucket and your ACK cluster must be created in the same region.

Step 2: Mount the OSS bucket to the ACK cluster

You can mount the OSS bucket to the ACK cluster only as a static volume.
  • Directly mount the OSS bucket as a volume
  • Use a pair of persistent volume (PV) and persistent volume claim (PVC). We recommend that you choose this method to mount OSS buckets to ACK clusters used in DLC.

In this topic, a pair of PV and PVC is used as an example. For more information about how to mount an OSS bucket in other ways, see Use OSS volumes.

  1. Log on to the ACK console.
  2. In the left-side navigation pane, choose Clusters > Persistent Volumes.
  3. Create a PV.
    1. On the Persistent Volumes page, select the target cluster and click Create.Create a PV
    2. Specify Volume Name, AccessKey ID, and AccessKey Secret.
    3. Click the Select Bucket hyperlink, and select the created OSS bucket.create PV
      Specify Endpoint:
      • If your OSS bucket and ACK cluster are deployed in different regions, select Public Endpoint.
      • If your OSS bucket and ACK cluster are deployed in the same region, select one of the following options based on the network of your ACK cluster.
        • If your ACK cluster is deployed in a VPC network, select VPC Endpoint.
        • If your ACK cluster is deployed in a classic network, select Internal Endpoint.
    4. Click Create.
  4. Create a PVC.
    1. On the Persistent Volumes page, click the Persistent Volume Claims tab.
    2. Select the target cluster from the Cluster list and click Create.
    3. Click the Select PV hyperlink next to Existing Volumes, and select the created PV.create PVC
    4. Click Create.