Hallo, ich würde gerne meine Medien alle auf dem GCP Bucket verwalten.
Shopware Version 6.2.2
config/packages/shopware.yml:
shopware:
cdn:
url: "https://storage.googleapis.com/xyz-ressources/"
strategy: "md5"
filesystem:
public:
type: "google-storage"
config:
bucket: "xyz-ressources"
keyFilePath: "/var/www/gcp_storage_key/json-key.json"
projectId: "XXXX"
Und beim Befehl: bin/console theme:compile bekomme ich folgende fehlermeldung:
15:49:16 ERROR [console] Error thrown while running command "theme:compile -vvv". Message: "League\Flysystem\Filesystem::putStream expects argument #2 to be a valid resource."
[
"exception" => InvalidArgumentException {
#message: "League\Flysystem\Filesystem::putStream expects argument #2 to be a valid resource."
#code: 0
#file: "./vendor/league/flysystem/src/Filesystem.php"
#line: 111
trace: {
./vendor/league/flysystem/src/Filesystem.php:111 { …}
./vendor/shopware/core/Framework/Adapter/Filesystem/Plugin/CopyBatch.php:35 { …}
Shopware\Core\Framework\Adapter\Filesystem\Plugin\CopyBatch->handle() {}
./vendor/league/flysystem/src/Plugin/PluggableTrait.php:72 { …}
./vendor/league/flysystem/src/Plugin/PluggableTrait.php:88 { …}
./vendor/shopware/storefront/Theme/ThemeCompiler.php:166 { …}
./vendor/shopware/storefront/Theme/ThemeCompiler.php:128 { …}
./vendor/shopware/storefront/Theme/ThemeService.php:82 { …}
./vendor/shopware/storefront/Theme/Command/ThemeCompileCommand.php:57 { …}
./vendor/symfony/console/Command/Command.php:255 { …}
./vendor/symfony/console/Application.php:1030 { …}
./vendor/symfony/framework-bundle/Console/Application.php:97 { …}
./vendor/symfony/console/Application.php:272 { …}
./vendor/symfony/framework-bundle/Console/Application.php:83 { …}
./vendor/symfony/console/Application.php:148 { …}
./bin/console:68 {
› $application = new Application($kernel->getKernel());
› $application->run($input);
›
arguments: {
$input: Symfony\Component\Console\Input\ArgvInput {#1 …}
}
}
}
},
"command" => "theme:compile -vvv",
"message" => "League\Flysystem\Filesystem::putStream expects argument #2 to be a valid resource."
]
15:49:16 DEBUG [console] Command "theme:compile -vvv" exited with code "1"
[
"command" => "theme:compile -vvv",
"code" => 1
]
In Filesystem.php line 111:
[InvalidArgumentException]
League\Flysystem\Filesystem::putStream expects argument #2 to be a valid resource.
Exception trace:
at /var/www/public/vendor/league/flysystem/src/Filesystem.php:111
League\Flysystem\Filesystem->putStream() at /var/www/public/vendor/shopware/core/Framework/Adapter/Filesystem/Plugin/CopyBatch.php:35
Shopware\Core\Framework\Adapter\Filesystem\Plugin\CopyBatch->handle() at n/a:n/a
call_user_func_array() at /var/www/public/vendor/league/flysystem/src/Plugin/PluggableTrait.php:72
League\Flysystem\Filesystem->invokePlugin() at /var/www/public/vendor/league/flysystem/src/Plugin/PluggableTrait.php:88
League\Flysystem\Filesystem->__call() at /var/www/public/vendor/shopware/storefront/Theme/ThemeCompiler.php:166
Shopware\Storefront\Theme\ThemeCompiler->copyAssets() at /var/www/public/vendor/shopware/storefront/Theme/ThemeCompiler.php:128
Shopware\Storefront\Theme\ThemeCompiler->compileTheme() at /var/www/public/vendor/shopware/storefront/Theme/ThemeService.php:82
Shopware\Storefront\Theme\ThemeService->compileTheme() at /var/www/public/vendor/shopware/storefront/Theme/Command/ThemeCompileCommand.php:57
Shopware\Storefront\Theme\Command\ThemeCompileCommand->execute() at /var/www/public/vendor/symfony/console/Command/Command.php:255
Symfony\Component\Console\Command\Command->run() at /var/www/public/vendor/symfony/console/Application.php:1030
Symfony\Component\Console\Application->doRunCommand() at /var/www/public/vendor/symfony/framework-bundle/Console/Application.php:97
Symfony\Bundle\FrameworkBundle\Console\Application->doRunCommand() at /var/www/public/vendor/symfony/console/Application.php:272
Symfony\Component\Console\Application->doRun() at /var/www/public/vendor/symfony/framework-bundle/Console/Application.php:83
Symfony\Bundle\FrameworkBundle\Console\Application->doRun() at /var/www/public/vendor/symfony/console/Application.php:148
Symfony\Component\Console\Application->run() at /var/www/public/bin/console:68
Ich weiß nicht, warum ich so einen Fehler bekomme. Ich habe einen weiteren SW6 Shop am laufen (version 6.1.5) und dort funktioniert es ohne Probleme. Hat jemand eine Idee?