Skip to content

Error while encryting a file to s3 #29

@UsamaKhan-hub

Description

@UsamaKhan-hub

Hello, what i am doing is basically i am uploading files on s3 as encrypted , it's working fine but when i tried to decrypt any specific file and create a presignedUrl (which i get and is accessible) and then i created a job to run after a while to again encrypt that specific file , jobs gets failed and it throws me this error :
Error: Call to undefined method League\Flysystem\Adapter\Local::getClient() in /vendor/soarecostin/file-vault/src/FileVault.php:192
Stack trace:

Sometime it works but most of time not. If someones guide me regarding this.
My code is as follow :
To create a url :
$presignedUrl=$client->getAwsTemporaryUrl($client->getDriver()->getAdapter(), $key, now()->addSeconds(15), []);

To decrypt the file again :
EncryptAttachment::dispatch($key1) ->onQueue('queue4') ->delay(now()->addSeconds(15));
and also i am specifying my disk as well in that job as well FileVault::disk('s3')->encrypt($this->key);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions