Open etraininteractive opened 1 year ago
are you using bedrock? The vendor directory structure is different than this code expects. I was able to get around my constant server error with this quick and dirty change on a fork https://github.com/nickdnickd/S3-Uploads/commit/26ef9f6d6138ff96b7b86fcbb95aead6a5f38d71
I am also seeing the CLI issue too though. For background I am running in a container. I can list the plugins, even re-activate the s3-uploads plugin, but I get the same error as your issue title.
@etraininteractive I was facing the same error few days ago . The way I figure it out was to activate the plugin ( wp plugin activate s3-uploads
) before running any other command. Have you tried that?
I got error:
Error: Callable "S3_Uploads\\WP_CLI_Command" does not exist, and cannot be registered as `wp s3-uploads`
find wp-cli.yml and add the code below
require:
- wp-content/plugins/s3-uploads/inc/class-wp-cli-command.php
after I run wp plugin activate s3-uploads
and wp s3-uploads verify
if configure the ENV correctly you should see the outputs below
Attempting to upload file s3://bucket-name/uploads/3682896686.txt
File uploaded to S3 successfully.
Attempting to delete file. s3://bucket-name/uploads/3682896686.txt
File deleted from S3 successfully.
Success: Looks like your configuration is correct.
when I try to use 'wp s3-uploads verify' command to verify my configuration of the plugin, it throws an error saying, "'s3-uploads' is not a registered wp command."
I tried to resole by using this code in s3-uploads in php: if ( ! class_exists( '\Aws\S3\S3Client' ) ) { // Require AWS Autoloader file. require_once dirname( DIR ) . '/vendor/autoload.php'; }
then, it throws CONSTANT error, even though I have added all the credentials like bucket name, bucket key and bucket secret in .env file.
Please help me to resolve this error.