Skip to content

Commit

Permalink
s3_delete; stub out backfill tool
Browse files Browse the repository at this point in the history
  • Loading branch information
thisisaaronland committed Jun 24, 2013
1 parent cb05a4b commit fc2fd5d
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
8 changes: 8 additions & 0 deletions bin/backfill_s3_paths.php
@@ -0,0 +1,8 @@
<?php

# update old-skool S3 bucket paths to new storagemaster_s3 paths/URLS

echo "please write me\n";
exit();

?>
8 changes: 6 additions & 2 deletions www/include/lib_storage_s3_new.php
Expand Up @@ -3,7 +3,7 @@
$GLOBALS['_storage_hooks']['file_exists'] = 'storage_s3_file_exists';
$GLOBALS['_storage_hooks']['get_file'] = 'storage_s3_get_file';
$GLOBALS['_storage_hooks']['put_file'] = 'storage_s3_put_file';
$GLOBALS['_storage_hooks']['delete_file'] = '';
$GLOBALS['_storage_hooks']['delete_file'] = 'storage_s3_delete_file';

loadlib('s3');

Expand Down Expand Up @@ -70,7 +70,11 @@ function storage_s3_put_file($path, $bytes, $more=array()) {
########################################################################

function storage_s3_delete_file($path, $more=array()){
# TO DO: grab code from mirror project (20130529/straup)

$bucket = storage_s3_bucket();

$rsp = s3_delete($bucket, $path);
return $rsp;
}

########################################################################
Expand Down

0 comments on commit fc2fd5d

Please sign in to comment.