How do I bulk upload to s3?

后端 未结 2 1458
甜味超标
甜味超标 2021-01-05 18:17

I recently refactored some of my code to stuff rows into a db using \'load data\' and it works great -- however for each record I have I must upload 2 files to s3 -- this to

2条回答
  •  借酒劲吻你
    2021-01-05 19:11

    I just found a nice solution to upload an entire directory with php:

    $client->uploadDirectory(
      SOURCE_FOLDER,
      YOUR_BUCKET_NAME,
      DESTINATION,
      array(
        'concurrency' => 5,
        'debug'          => TRUE,
        'force'            => FALSE,
        'params'        => array(
          'ServerSideEncryption' => 'AES256',
        ),
      )
    );
    

提交回复
热议问题