src/Webiny/BackupService/Lib/S3.php
public function deleteBackup($backupName)
    {
        Service::$log->msg('S3: deleting backup ' . $backupName);
        $destinationFile = rtrim($this->s3Config->RemotePath, '/') . '/' . $backupName;

        if ($this->s3Instance->doesObjectExist($this->s3Config->Bucket, $destinationFile)) {
            $this->s3Instance->deleteObject($this->s3Config->Bucket, $destinationFile);
        }

        Service::$log->msg('S3: backup deleted ' . $backupName);
    }
public function deleteBackup($backupName)
    {
        Service::$log->msg('S3: deleting backup ' . $backupName);
        $destinationFile = rtrim($this->s3Config->RemotePath, '/') . '/' . $backupName;

        if ($this->s3Instance->doesObjectExist($this->s3Config->Bucket, $destinationFile)) {
            $this->s3Instance->deleteObject($this->s3Config->Bucket, $destinationFile);
        }

        Service::$log->msg('S3: backup deleted ' . $backupName);
    }
public function deleteBackup ( $ backupName ) { Service :: $ log -> msg ( 'S3: deleting backup ' . $ backupName ) ; $ destinationFile = rtrim ( $ this -> s3Config -> RemotePath , '/' ) . '/' . $ backupName ; if ( $ this -> s3Instance -> doesObjectExist ( $ this -> s3Config -> Bucket , $ destinationFile ) ) { $ this -> s3Instance -> deleteObject ( $ this -> s3Config -> Bucket , $ destinationFile ) ; } Service :: $ log -> msg ( 'S3: backup deleted ' . $ backupName ) ; }
Deletes a given backup from the S3 bucket.

@param string $backupName Backup filename on S3.
Deletes a given backup from the S3 bucket .