我正在将带有框架symfony 5的php 7.4应用程序部署在Google App Engine上。
问题是,在App Engine上已部署的应用程序的源文件夹“供应商”中看不到friendsofsymfony软件包。
我在Symfony FOSCKEditorBundle上安装了软件包 (下载捆绑软件,注册捆绑软件,安装资产,配置树枝)。 我确实在公共内部拥有捆绑包,但是composer似乎没有在供应商文件夹中安装ckeditor-bundle软件包。在本地,一切正常,在作曲家安装/更新后,他下载了软件包,应用运行正常。
Composer.json
{
"type": "project",
"license": "proprietary",
"require": {
"php": "^7.2.5",
"ext-ctype": "*",
"ext-iconv": "*",
"friendsofsymfony/ckeditor-bundle": "^2.2",
"google/cloud-dialogflow": "^0.13.0",
"knplabs/knp-paginator-bundle": "^5.2",
"league/csv": "^9.0",
"nelmio/cors-bundle": "^2.0",
"sendgrid/sendgrid": "^7.7",
"sensio/framework-extra-bundle": "^5.5",
"symfony/apache-pack": "^1.0",
"symfony/asset": "5.0.*",
"symfony/console": "5.0.*",
"symfony/dotenv": "5.0.*",
"symfony/expression-language": "5.0.*",
"symfony/flex": "^1.3.1",
"symfony/form": "5.0.*",
"symfony/framework-bundle": "5.0.*",
"symfony/http-client": "5.0.*",
"symfony/intl": "5.0.*",
"symfony/mailer": "5.0.*",
"symfony/monolog-bundle": "^3.1",
"symfony/notifier": "5.0.*",
"symfony/orm-pack": "*",
"symfony/process": "5.0.*",
"symfony/security-bundle": "5.0.*",
"symfony/serializer": "5.0.*",
"symfony/serializer-pack": "*",
"symfony/string": "5.0.*",
"symfony/translation": "5.0.*",
"symfony/twig-pack": "^1.0",
"symfony/validator": "5.0.*",
"symfony/web-link": "5.0.*",
"symfony/yaml": "5.0.*"
},
"require-dev": {
"symfony/debug-pack": "*",
"symfony/maker-bundle": "^1.0",
"symfony/profiler-pack": "*",
"symfony/test-pack": "*"
},
"config": {
"preferred-install": {
"*": "dist"
},
"sort-packages": true
},
"autoload": {
"psr-4": {
"App\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"App\\Tests\\": "tests/"
}
},
"replace": {
"paragonie/random_compat": "2.*",
"symfony/polyfill-ctype": "*",
"symfony/polyfill-iconv": "*",
"symfony/polyfill-php72": "*",
"symfony/polyfill-php71": "*",
"symfony/polyfill-php70": "*",
"symfony/polyfill-php56": "*"
},
"conflict": {
"symfony/symfony": "*"
},
"extra": {
"symfony": {
"allow-contrib": false,
"require": "5.0.*"
}
}
}
app.yaml
# Use the PHP 7.3 runtime (BETA) by replacing "php72" below with "php73"
runtime: php74
env_variables:
APP_ENV: prod
APP_SECRET: ###
DATABASE_URL: ###
# APP_DEBUG: true
## For connecting to Cloud SQL with Doctrine
## This is used in part two of the README:
# DATABASE_URL: mysql://root:DB_PASSWORD@localhost?unix_socket=/cloudsql/INSTANCE_CONNECTION_NAME;dbname=symfonydb
handlers:
# Declare the build and bundles directory as static assets to be served by the
# App Engine CDN.
- url: /build
static_dir: public
- url: /bundles
static_dir: public
# Declare any media files in the public directory as static assets as well.
- url: /css
static_dir: css
- url: /js
static_dir: js
- url: /images
static_dir: images
- url: /node_modules
static_dir: node_modules
- url: /Theme/META-INF/resources
static_dir: Theme/META-INF/resources
- url: /bundles/fosckeditor
static_dir: bundles/fosckeditor
basic_scaling:
max_instances: 5
fos_ckeditor.yaml
# Read the documentation: https://symfony.com/doc/current/bundles/FOSCKEditorBundle/index.html
twig:
form_themes:
- '@FOSCKEditor/Form/ckeditor_widget.html.twig'
fos_ck_editor:
configs:
main_config:
toolbar:
- { name: "styles", items: ['Bold', 'Italic', 'Underline', 'Strike', 'Blockquote', '-', 'Link', '-', 'RemoveFormat', '-', 'NumberedList', 'BulletedList', '-', 'Image', 'Table', '-', 'TextColor', 'BGColor', 'Source'] }