Я пытаюсь запустить DreamFactory 2.0 на BlueMix. Я выполнил инструкции, приведенные на https://developer.ibm.com/bluemix/2014/06/17/getting-started-laravel-bluemix/, на запуск приложений Laravel на BlueMix. У меня есть все под htdocs, за исключением .bp-config, .cfignore, manifest.yml и composer.json. Я изменил путь к artisan для всех скриптов в composer.json, а затем сделал
cf push df2
В сообщениях журнала я вижу, как устанавливается php buildpack, все модули, а затем
/tmp/staged/app/php/bin/php /tmp/staged/app/php/bin/composer.phar install --no-progress --no-interaction --no-dev
Зависимости устанавливаются просто отлично, тогда я вижу
Writing lock file Generating autoload files [RuntimeException] Could not scan for classes inside "database" which does not appear to be a file nor a folder install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--no-plugins] [--no-custom-installers] [--no-autoloader] [--no-scripts] [--no-progress] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [--ignore-platform-reqs] [packages1] ... [packagesN] -----> Composer command failed Traceback (most recent call last): File "/tmp/buildpacks/php-buildpack/scripts/compile.py", line 51, in <module> .from_build_pack('lib/additional_commands') File "/tmp/buildpacks/php-buildpack/lib/build_pack_utils/builder.py", line 189, in extensions process_extension(path, ctx, 'compile', process, args=[self]) File "/tmp/buildpacks/php-buildpack/lib/build_pack_utils/utils.py", line 69, in process_extension success(getattr(extn, to_call)(*args)) File "/tmp/buildpacks/php-buildpack/extensions/composer/extension.py", line 420, in compile return composer.compile(install) File "/tmp/buildpacks/php-buildpack/lib/extension_helpers.py", line 154, in compile self._compile(install) File "/tmp/buildpacks/php-buildpack/extensions/composer/extension.py", line 173, in _compile self.run() File "/tmp/buildpacks/php-buildpack/extensions/composer/extension.py", line 305, in run *self._ctx['COMPOSER_INSTALL_OPTIONS']) File "/tmp/buildpacks/php-buildpack/extensions/composer/extension.py", line 350, in run shell=True) File "/tmp/buildpacks/php-buildpack/lib/build_pack_utils/runner.py", line 109, in stream_output raise CalledProcessError(retcode, cmd) build_pack_utils.runner.CalledProcessError: Command '<open file '<fdopen>', mode 'w' at 0x7ffa34c4d810>' returned non-zero exit status 1 Staging failed: Buildpack compilation step failed
Вот мои файлы:
--- applications: - name: df2 memory: 512M buildpack: https://github.com/cloudfoundry/php-buildpack#v3.2.2 env: CF_STAGING_TIMEOUT: 15 CF_STARTUP_TIMEOUT: 15 BP_DEBUG: "True" services: - df2-cleardb
{ "WEB_SERVER": "nginx", "LIBDIR": ".", "COMPOSER_VENDOR_DIR": "htdocs/vendor", "WEBDIR": "htdocs/public", "NGINX_VERSION": "{NGINX_16_LATEST}", "PHP_VERSION": "{PHP_56_LATEST}", "PHP_EXTENSIONS": [ "bz2", "curl", "fileinfo", "ldap", "mbstring", "mcrypt", "mongo", "mysql", "openssl", "pdo", "pdo_mysql", "pdo_sqlite", "pgsql", "redis", "sockets", "zip", "zlib" ] }
{ "name": "dreamfactory/dreamfactory", "description": "The DreamFactory(tm) Platform.", "keywords": [ "api", "dreamfactory", "dsp", "rest" ], "homepage": "https://www.dreamfactory.com/", "license": "Apache-2.0", "authors": [ { "name": "Arif Islam", "email": "arifislam@dreamfactory.com" }, { "name": "David Weiner", "email": "davidweiner@dreamfactory.com" }, { "name": "Jerry Ablan", "email": "jerryablan@dreamfactory.com" }, { "name": "Lee Hicks", "email": "leehicks@dreamfactory.com" } ], "support": { "email": "support@dreamfactory.com", "source": "https://github.com/dreamfactorysoftware/dreamfactory", "issues": "https://github.com/dreamfactorysoftware/dreamfactory/issues", "wiki": "https://wiki.dreamfactory.com" }, "minimum-stability": "dev", "prefer-stable": true, "require": { "laravel/framework": "5.1.*", "tymon/jwt-auth": "0.5.*", "dreamfactory/df-managed": "dev-feature/bluemix_debug as dev-master", "dreamfactory/df-admin-app": "2.0.*", "dreamfactory/df-core": "0.1.*", "dreamfactory/df-aws": "0.1.*", "dreamfactory/df-rackspace": "0.1.*", "dreamfactory/df-sqldb": "0.1.*", "dreamfactory/df-mongodb": "0.1.*", "dreamfactory/df-couchdb": "0.1.*", "dreamfactory/df-rws": "0.1.*", "dreamfactory/df-salesforce": "0.1.*", "dreamfactory/df-soap": "0.1.*", "dreamfactory/df-user": "0.1.*", "dreamfactory/df-oauth": "0.1.*", "dreamfactory/df-adldap": "0.1.*" }, "require-dev": { "barryvdh/laravel-ide-helper": "~2.0", "laracasts/generators": "~1.0", "laracasts/testdummy": "~2.0", "phpunit/phpunit": "~4.0", "phpspec/phpspec": "~2.1", "laravel/homestead": "dev-master" }, "autoload": { "classmap": [ "database" ], "psr-4": { "DreamFactory\\": "htdocs/app/" } }, "autoload-dev": { "classmap": [ "tests/TestCase.php" ] }, "scripts": { "pre-install-cmd": [ "echo \"\npath is $PWD\nls is\n$(ls -al)\"", "rm -rf htdocs/bootstrap/cache/*.php" ], "post-install-cmd": [ "echo \"\npath is $PWD\nls is\n$(ls -al)\"", "php htdocs/artisan clear-compiled", "php htdocs/artisan optimize", "php htdocs/artisan dreamfactory:pull-migrations --dst=htdocs/database/migrations", "php htdocs/artisan dreamfactory:setup --force --bluemix" ], "post-update-cmd": [ "php htdocs/artisan clear-compiled", "php htdocs/artisan optimize", "php htdocs/artisan dreamfactory:pull-migrations --dst=htdocs/database/migrations", "php htdocs/artisan dreamfactory:homestead-config" ] }, "config": { "preferred-install": "source" }, "extra": { "branch-alias": { "dev-develop": "2.0.x-dev" }, "installer-paths": { "public/{$name}/": [ "type:dreamfactory-app" ] } } }
Команда dreamfactory: pull-migrations в post-install-cmd и post-update-cmd собирает все миграции из каталога поставщика (знаю, я знаю. Не мой проект) и помещает их в каталог htdocs / database / migrations , Команда dreamfactory: setup создаст файл .env, запустит ключ: generate, migrate и db: seed
Основываясь на сообщении об ошибке, это звучит как dreamfactory: pull-migrations не запускается или выдается ошибка, но поскольку приложение не запускается, у меня нет способа взглянуть на файловую структуру.
Кто-нибудь есть идеи о том, почему он не работает? Мы используем Laravel 5.1.
Благодаря!