我刚刚按照以下步骤在Google GCP App Engine STANDARD环境中安装了WordPress的新副本:https://cloud.google.com/community/tutorials/run-wordpress-on-appengine-standard
最后一步还不清楚或不完整。我已经创建了存储桶(GCP存储),安装了GCS官方插件(0.1.5),但是当我在媒体文件夹上上传一些图像时,出现此错误:
Fatal error: Uncaught GuzzleHttp\Exception\ClientException: Client error: `GET https://www.googleapis.com/storage/v1/b/xxx-news.appspot.com/o/1%2F2019%2F11` resulted in a `404 Not Found` response: { "error": { "code": 404, "message": "No such object: xxx-news.appspot.com/1/2019/11", "errors": [ (truncated...) in /srv/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php:113 Stack trace: #0 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/Middleware.php(66): GuzzleHttp\Exception\RequestException::create(Object(GuzzleHttp\Psr7\Request), Object(GuzzleHttp\Psr7\Response)) #1 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/promises/src/Promise.php(203): GuzzleHttp\Middleware::GuzzleHttp\{closure}(Object(GuzzleHttp\Psr7\Response)) #2 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/promises/src/Promise.php(156): GuzzleHttp\Promise\Promise::callHandler(1, Object(GuzzleHttp\Psr7\Response), Array) #3 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/promises/src/TaskQueue.php(47): GuzzleHttp\Promise\Promise::GuzzleHttp\Promise\{closure}() #4 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/promises/src/Promise.php(246): GuzzleHttp\Promise\TaskQueue->run(true) #5 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/promises/src/Promise.php(223): GuzzleHttp\Promise\Promise->invokeWaitFn() #6 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/promises/src/Promise.php(267): GuzzleHttp\Promise\Promise->waitIfPending() #7 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/promises/src/Promise.php(225): GuzzleHttp\Promise\Promise->invokeWaitList() #8 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/promises/src/Promise.php(62): GuzzleHttp\Promise\Promise->waitIfPending() #9 /srv/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/Client.php(106): GuzzleHttp\Promise\Promise->wait() #10 /srv/wp-content/plugins/gcs/vendor/google/auth/src/HttpHandler/Guzzle6HttpHandler.php(34): GuzzleHttp\Client->send(Object(GuzzleHttp\Psr7\Request), Array) #11 [internal function]: Google\Auth\HttpHandler\Guzzle6HttpHandler->__invoke(Object(GuzzleHttp\Psr7\Request), Array) #12 /srv/wp-content/plugins/gcs/gcs.php(134): call_user_func_array(Object(Google\Auth\HttpHandler\Guzzle6HttpHandler), Array) #13 [internal function]: Google\Cloud\Storage\WordPress\{closure}(Object(GuzzleHttp\Psr7\Request), Array) #14 /srv/wp-content/plugins/gcs/vendor/google/cloud-core/src/ExponentialBackoff.php(74): call_user_func_array(Object(Closure), Array) #15 /srv/wp-content/plugins/gcs/vendor/google/cloud-core/src/RequestWrapper.php(166): Google\Cloud\Core\ExponentialBackoff->execute(Object(Closure), Array) #16 /srv/wp-content/plugins/gcs/vendor/google/cloud-core/src/RestTrait.php(95): Google\Cloud\Core\RequestWrapper->send(Object(GuzzleHttp\Psr7\Request), Array) #17 /srv/wp-content/plugins/gcs/vendor/google/cloud-storage/src/Connection/Rest.php(195): Google\Cloud\Storage\Connection\Rest->send('objects', 'get', Array) #18 /srv/wp-content/plugins/gcs/vendor/google/cloud-storage/src/StorageObject.php(1123): Google\Cloud\Storage\Connection\Rest->getObject(Array) #19 /srv/wp-content/plugins/gcs/vendor/google/cloud-storage/src/StorageObject.php(1074): Google\Cloud\Storage\StorageObject->reload(Array) #20 /srv/wp-content/plugins/gcs/vendor/google/cloud-storage/src/StreamWrapper.php(583): Google\Cloud\Storage\StorageObject->info() #21 /srv/wp-content/plugins/gcs/vendor/google/cloud-storage/src/StreamWrapper.php(488): Google\Cloud\Storage\StreamWrapper->urlStatFile() #22 [internal function]: Google\Cloud\Storage\StreamWrapper->url_stat('gs://xxx-news....', 2) #23 /srv/wp-includes/functions.php(1922): file_exists('gs://xxx-news....') #24 /srv/wp-includes/functions.php(2254): wp_mkdir_p('gs://xxx-news....') #25 /srv/wp-admin/includes/file.php(837): wp_upload_dir('2019-11-20 11:1...') #26 /srv/wp-admin/includes/file.php(953): _wp_handle_upload(Array, Array, '2019-11-20 11:1...', 'wp_handle_uploa...') #27 /srv/wp-admin/includes/media.php(301): wp_handle_upload(Array, Array, '2019-11-20 11:1...') #28 /srv/wp-admin/async-upload.php(93): media_handle_upload('async-upload', 0) #29 /srv/gae-app.php(53): require('/srv/wp-admin/a...') #30 {main} thrown in /srv/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php on line 113
我想我的ACL许可上缺少某些内容,但我不知道如何进行
谢谢!
答案 0 :(得分:1)
GCS 0.1.5呈现了媒体加载错误 我改用0.1.4
https://github.com/GoogleCloudPlatform/wordpress-plugins/issues/68