Symfony + Travis-CI + Heroku + GitHub basic .gitignore and travis.yml? - php

I created a Symfony project with the composer command: "composer create-project symfony/framework-standard-edition my_project_name" and I put it under version control using git and GitHub as remote hosting.
In addittion I need to use Travis-CI for continuous integration and status checking, together with Heroku for deployment.
Being the first time I use Symfony, travis and heroku I am having some trouble with their configuration files.
This is my .gitignore file:
/.idea
/app/config/parameters.yml
/build/
/phpunit.xml
/var/*
!/var/cache
/var/cache/*
!var/cache/.gitkeep
!/var/logs
/var/logs/*
!var/logs/.gitkeep
!/var/sessions
/var/sessions/*
!var/sessions/.gitkeep
!var/SymfonyRequirements.php
/vendor/
/web/bundles/
And this is my .travis.yml file:
language: php
php:
- '5.5'
- '5.6'
- '7.0'
- hhvm
- nightly
This is the log of travis-ci failing
What I understood is that there is a lack of dependencies under vendor directory, which has been ignored by git due to solve the error message of heroku bild:
-----> PHP app detected
-----> Bootstrapping...
-----> Installing platform packages...
- php (7.1.0)
- apache (2.4.20)
- nginx (1.8.1)
-----> Installing dependencies...
Composer version 1.2.2 2016-11-03 17:43:15
! WARNING: Your Composer vendor dir is part of your Git repository.
This directory should not be under version control; only your
'composer.json' and 'composer.lock' files should be added, which
will let Composer handle installation of dependencies on deploy.
To suppress this notice, first remove the folder from your index
by running 'git rm -r --cached vendor/'.
Next, edit your project's '.gitignore' file and add the folder
'/vendor/' to the list.
For more info, refer to the Composer FAQ: https://getcomposer.org/doc/faqs/should-i-commit-the-dependencies-in-my-vendor-directory.md
Loading composer repositories with package information
Installing dependencies from lock file
- Removing symfony/phpunit-bridge (v3.1.7)
- Removing sensio/generator-bundle (v3.1.1)
Generating optimized autoload files
> Incenteev\ParameterHandler\ScriptHandler::buildParameters
Updating the "app/config/parameters.yml" file
> Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::buildBootstrap
> Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache
PHP Fatal error: Uncaught Symfony\Component\Debug\Exception\ClassNotFoundException: Attempted to load class "SensioGeneratorBundle" from namespace "Sensio\Bundle\GeneratorBundle".
Did you forget a "use" statement for another namespace? in /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/app/AppKernel.php:25
Stack trace:
#0 /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php(396): AppKernel->registerBundles()
#1 /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php(114): Symfony\Component\HttpKernel\Kernel->initializeBundles()
#2 /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/Console/Application.php(68): Symfony\Component\HttpKernel\Kernel->boot()
#3 /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/vendor/symfony/symfony/src/Symfony/Component/Console/Appli in /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/app/AppKernel.php on line 25
Script Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache handling the symfony-scripts event terminated with an exception
[RuntimeException]
An error occurred when executing the "'cache:clear --no-warmup'" command:
PHP Fatal error: Uncaught Symfony\Component\Debug\Exception\ClassNotFoundException: Attempted to load class "SensioGeneratorBundle" from namespace "Sensio\Bundle\GeneratorBundle".
Did you forget a "use" statement for another namespace? in /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/app/AppKernel.php:25
Stack trace:
#0 /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php(396): AppKernel->registerBundles()
#1 /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php(114): Symfony\Component\HttpKernel\Kernel->initializeBundles()
#2 /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/Console/Application.php(68): Symfony\Component\HttpKernel\Kernel->boot()
#3 /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/vendor/symfony/symfony/src/Symfony/Component/Console/Appli in /tmp/build_3481ed5a9ce634e19d2af5d00bd7a3f9/izio7-YourTeam-8f31587/app/AppKernel.php on line 25
.
install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--no-custom-installers] [--no-autoloader] [--no-scripts] [--no-progress] [--no-suggest] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--ignore-platform-reqs] [--] [<packages>]...
! Push rejected, failed to compile PHP app.
! Push failed
Is there some command or change I can do, in order to make it work both with travis-ci and heroku without versioning the vendor directory or in some other way? Thanks in advance.

I solved the problem by updating the .travis.yml with composer install.
language: php
php:
- '5.5'
- '5.6'
- '7.0'
- hhvm
- nightly
before_script: composer install

Related

\[InvalidArgumentException\] Could not find package vlucas/phpdotenv. Couldn't download package

I'm having a problem with vlucas/phpdotenv installation
 ~/ nslookup repo.packagist.org
Server: 8.8.8.8
Address: 8.8.8.8#53
Non-authoritative answer:
Name: repo.packagist.org
Address: 54.37.2.184
My composer.json:
{
"name": "developer/mvc",
"authors": [
{
"name": "Abubakr Abduvakhidov",
"email": "abubakr#edu.thedevs.co"
}
],
"autoload": {
"psr-4": {
"app\\": "."
}
},
"require": {}
}
Output of composer diagnose:
Checking platform settings: OK
Checking git settings: OK
Checking http connectivity to packagist: OK
Checking https connectivity to packagist: OK
Checking github.com rate limit: OK
Checking disk free space: OK
Checking pubkeys:
Tags Public Key Fingerprint: 57815BA2 7E54DC31 7ECC7CC5 573090D0 87719BA6 8F3BB723 4E5D42D0 84A14642
Dev Public Key Fingerprint: 4AC45767 E5EC2265 2F0C1167 CBBB8A2B 0C708369 153E328C AD90147D AFE50952
OK
Checking composer version: OK
Composer version: 2.0.8
PHP version: 7.4.12
PHP binary path: /usr/local/Cellar/php/7.4.12/bin/php
OpenSSL version: OpenSSL 1.1.1h 22 Sep 2020
cURL version: 7.73.0 libz 1.2.11 ssl OpenSSL/1.1.1h
zip: extension present, unzip present
When I run this command:
composer require vlucas/phpdotenv -vvv
I get the following output:
Loading config file /Users/abubakr/.composer/config.json
Loading config file /Users/abubakr/.composer/auth.json
Failed to initialize global composer: Composer could not find the config file: /Users/abubakr/.composer/composer.json
To initialize a project, please create a composer.json file as described in the https://getcomposer.org/ "Getting Started" section
Running 2.0.8 (2020-12-03 17:20:38) with PHP 7.4.12 on Darwin / 20.1.0
Loading config file /Users/abubakr/.composer/config.json
Loading config file /Users/abubakr/.composer/auth.json
Failed to initialize global composer: Composer could not find the config file: /Users/abubakr/.composer/composer.json
To initialize a project, please create a composer.json file as described in the https://getcomposer.org/ "Getting Started" section
Reading ./composer.json
Loading config file /Users/abubakr/.composer/config.json
Loading config file /Users/abubakr/.composer/auth.json
Loading config file ./composer.json
Checked CA file /usr/local/etc/openssl#1.1/cert.pem: valid
Executing command (/Users/abubakr): git branch -a --no-color --no-abbrev -v
Executing command (/Users/abubakr): git describe --exact-match --tags
Executing command (CWD): git --version
Executing command (/Users/abubakr): git log --pretty="%H" -n1 HEAD --no-show-signature
Executing command (/Users/abubakr): hg branch
Executing command (/Users/abubakr): fossil branch list
Executing command (/Users/abubakr): fossil tag list
Executing command (/Users/abubakr): svn info --xml
Failed to initialize global composer: Composer could not find the config file: /Users/abubakr/.composer/composer.json
To initialize a project, please create a composer.json file as described in the https://getcomposer.org/ "Getting Started" section
Downloading https://packagist.phpcomposer.com/packages.json
[200] https://packagist.phpcomposer.com/packages.json
Writing /Users/abubakr/.composer/cache/repo/https---packagist.phpcomposer.com/packages.json into cache
Downloading https://packagist.phpcomposer.com/p2/vlucas/phpdotenv.json
[404] https://packagist.phpcomposer.com/p2/vlucas/phpdotenv.json
Downloading https://packagist.phpcomposer.com/p2/vlucas/phpdotenv~dev.json
[404] https://packagist.phpcomposer.com/p2/vlucas/phpdotenv~dev.json
Downloading https://packagist.org/search.json?q=vlucas/phpdotenv&type=
[200] https://packagist.org/search.json?q=vlucas/phpdotenv&type=
[RuntimeException]
No composer.json present in the current directory, this may be the cause of
the following exception.
Exception trace:
() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/src/Composer/Command/RequireCommand.php:193
Composer\Command\RequireCommand->execute() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/vendor/symfony/console/Command/Command.php:245
Symfony\Component\Console\Command\Command->run() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/vendor/symfony/console/Application.php:835
Symfony\Component\Console\Application->doRunCommand() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/vendor/symfony/console/Application.php:185
Symfony\Component\Console\Application->doRun() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/src/Composer/Console/Application.php:310
Composer\Console\Application->doRun() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/vendor/symfony/console/Application.php:117
Symfony\Component\Console\Application->run() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/src/Composer/Console/Application.php:122
Composer\Console\Application->run() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/bin/composer:63
require() at /usr/local/Cellar/composer/2.0.6/bin/composer:24
[InvalidArgumentException]
Could not find package vlucas/phpdotenv.
Did you mean one of these?
vlucas/phpdotenv
sobyte/dotenv-php
calgamo/module-php-dotenv
abacaphiliac/zend-phpdotenv
davek1312/config
Exception trace:
() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/src/Composer/Command/InitCommand.php:796
Composer\Command\InitCommand->findBestVersionAndNameForPackage() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/src/Composer/Command/InitCommand.php:430
Composer\Command\InitCommand->determineRequirements() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/src/Composer/Command/RequireCommand.php:189
Composer\Command\RequireCommand->execute() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/vendor/symfony/console/Command/Command.php:245
Symfony\Component\Console\Command\Command->run() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/vendor/symfony/console/Application.php:835
Symfony\Component\Console\Application->doRunCommand() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/vendor/symfony/console/Application.php:185
Symfony\Component\Console\Application->doRun() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/src/Composer/Console/Application.php:310
Composer\Console\Application->doRun() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/vendor/symfony/console/Application.php:117
Symfony\Component\Console\Application->run() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/src/Composer/Console/Application.php:122
Composer\Console\Application->run() at phar:///usr/local/Cellar/composer/2.0.6/bin/composer/bin/composer:63
require() at /usr/local/Cellar/composer/2.0.6/bin/composer:24
require [--dev] [--dry-run] [--prefer-source] [--prefer-dist] [--fixed] [--no-suggest] [--no-progress] [--no-update] [--no-install] [--no-scripts] [--update-no-dev] [-w|--update-with-dependencies] [-W|--update-with-all-dependencies] [--with-dependencies] [--with-all-dependencies] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--apcu-autoloader-prefix APCU-AUTOLOADER-PREFIX] [--] [<packages>]...
And I expected this to happen:
package to be installed
Additional:
 /Applications/XAMPP/xamppfiles/htdocs/php/mvc/ [master+*] which composer
/usr/local/bin/composer
 /Applications/XAMPP/xamppfiles/htdocs/php/mvc/ [master+*] alias | grep composer
 /Applications/XAMPP/xamppfiles/htdocs/php/mvc/ [master+*] ls
composer.json core models vendor
composer.lock migrations public views
controllers migrations.php runtime
Actually, it was because of loading metadata from https://packagist.phpcomposer.com/packages.json, which is not the official Packagist, but an official mirror (and a broken one according to the list in https://github.com/Webysther/packagist-mirror#-packagist-public-metadata-mirrors-observatory-around-the-world)
That's probably the reason for the issue: the package is not found in the metadata in this repository, but the repository still exposes the official search endpoint instead of a mirrored one, which is used by composer when looking for alternative names.
After running the command in the bottom it started downloading
composer config -g repo.packagist composer https://packagist.org

failed to install composer packages in docker container

Since a few days i cant install composer-packages anymore in my local docker container.
I create new composer.json with composer init and try to add a package with composer require fzaninotto/faker
Always i get the same error message
# composer require fzaninotto/faker
Using version ^1.9 for fzaninotto/faker
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
Failed to download fzaninotto/faker from dist: The zip extension and unzip command are both missing, skipping.
Your command-line PHP is using multiple ini files. Run `php --ini` to show them.
Now trying to download from source
- Installing fzaninotto/faker (v1.9.1): Cloning fc10d778e4 from cache
fc10d778e4b84d5bd315dad194661e091d307c6f is gone (history was rewritten?)
Installation failed, reverting ./composer.json to its original content.
[RuntimeException]
Failed to execute git checkout 'fc10d778e4b84d5bd315dad194661e091d307c6f' -- && git reset --hard 'fc10d778e4b84d5bd315dad194661e091d307c6f' --
fatal: failed to read object fc10d778e4b84d5bd315dad194661e091d307c6f: Operation not permitted
require [--dev] [--prefer-source] [--prefer-dist] [--fixed] [--no-progress] [--no-suggest] [--no-update] [--no-scripts] [--update-no-dev] [--update-with-dependencies] [--update-with-all-dependencies] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--] [<packages>]...
First i guess my ssh key is the problem but i create a new one and add this to github with the same error.
Than i try it with composer clear and the problem don't resolved.
The problem come in EACH docker container and EACH composer packages... so i cant be a problem with single packages or container.
Have anyone an idea that i can do to use composer again?
If you're using Docker Desktop (Windows) and you updated to the latest version 2.2.0.4, then you get this issue.
Downgrade to the 2.2.0.3 and it should work again (at least it did for me).
See: https://forums.docker.com/t/issues-after-upgrading-docker-desktop-to-2-2-0-4/90589
To downgrade:
Uninstall Docker Desktop. Attention: it will delete your containers, save them before if you want to import them back
Go this page: https://docs.docker.com/docker-for-windows/release-notes/
Click Download under 2.2.0.3
Install Docker Desktop with the installer file
When started it will ask to upgrade to 2.2.0.4, just say "Skip this build"
I didn't have enough points to comment on the top answer but the Docker issue was just closed (like an hour ago!) and so simply updating Docker Desktop on Windows should fix it. Worked for me at least. Now I can install Drupal again!

Unable to install laravel on bitnami wamp

I am totally new to laravel. I would like to use it in my project
I downloaded WAMP Stack 7.1.26-2 from http://bitnami.com and to my surprise,it already came with laravel pre-installed.
It is in the frameworks folder as in:C:\Bitnami\wampstack-7.1.26-2\frameworks
But my problem is that I do not kinow how to use laravel from there.It is not in the htdocs folder as I think it s supposed to be.
If I go to http://localhost I see only the bitnami welcome page
If i go to http://localhost/laravel ,it says PAGE NOT FOUND
I searched online for the answer but most of the time,it points me to this link:
https://docs.bitnami.com/google/apps/#laravel
But on that page, I see NOTHING relating to laravel.I cannot even find the word 'laravel' with a browser search.
If I run composer create-project laravel/laravel myproject --prefer-dist ,
I get this:
Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.
C:\Users\o.o amoo>composer create-project laravel/laravel myproject --prefer-dist
PHP Warning: PHP Startup: Unable to load dynamic library 'C:/Bitnami/wampstack-
7.0.0RC7-/php/ext\php_solr.dll' - The specified module could not be found.
in Unknown on line 0
Installing laravel/laravel (v5.5.28)
- Installing laravel/laravel (v5.5.28): Loading from cache
Created project in myproject
> #php -r "file_exists('.env') || copy('.env.example', '.env');"
PHP Warning: PHP Startup: Unable to load dynamic library 'C:/Bitnami/wampstack-
7.0.0RC7-/php/ext\php_solr.dll' - The specified module could not be found.
in Unknown on line 0
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 73 installs, 0 updates, 0 removals
- Installing symfony/thanks (v1.1.0): Loading from cache
- Installing symfony/polyfill-ctype (v1.10.0): Loading from cache
Invalid zip file, retrying...
- Installing symfony/polyfill-ctype (v1.10.0): Loading from cache
Invalid zip file, retrying...
- Installing symfony/polyfill-ctype (v1.10.0): Loading from cache
Failed to download symfony/polyfill-ctype from dist: 'C:\Users\o.o amoo\
myproject\vendor/symfony/polyfill-ctype/4199a310f6ba3768faedee6d521ec615' is not a zi
p archive.
Now trying to download from source
- Installing symfony/polyfill-ctype (v1.10.0): Cloning e3d8262452
[RuntimeException]
Failed to clone https://github.com/symfony/polyfill-ctype.git via https, ssh p
rotocols, aborting.
- https://github.com/symfony/polyfill-ctype.git
Cloning into 'C:\Users\o.o amoo\myproject\vendor\symfony\polyfill-ctype'...
fatal: unable to access 'https://github.com/symfony/polyfill-ctype.git/': Fa
iled to connect to github.com port 443: Timed out
- git#github.com:symfony/polyfill-ctype.git
Cloning into 'C:\Users\o.o amoo\myproject\vendor\symfony\polyfill-ctype'...
ssh: connect to host github.com port 22: Connection timed out
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--r
epository REPOSITORY] [--repository-url REPOSITORY-URL] [--dev] [--no-dev] [--no
-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-vc
s] [--remove-vcs] [--no-install] [--ignore-platform-reqs] [--] [<package>] [<dir
ectory>] [<version>]
C:\Users\o.o amoo>
That made me soo confused.It did make a project called myproject was made in : C:\Users\o.o amoo>
but laravel couldn't be installed???
If I try php artisan serve I get:
Could not open input file:artisan
So with that,can I access myproject with laarvel if so,how?If not how come and what do I do?
Someone please point me in the right direction...
Thanks!!!
Alright let's start with why your project is installed in C:/Users it's because you use --prefer-dist in composer create-project laravel/laravel myproject --prefer-dist.
--prefer-dist: Reverse of --prefer-source, composer will install from dist if possible. This can speed up installs substantially on build
servers and other use cases where you typically do not run updates of
the vendors. It is also a way to circumvent problems with git if you
do not have a proper setup.
Second you run into errors maybe because you are in a directory that require additional rights, at least that's how it looks to me.
If you have installed Laravel correctly you should be able to navigate trough a terminal to the desired location, and either use laravel new BUT only if you are already in the directory that you want say C:/Code/myproject if you are still in C/Code you need to do laravel new myproject
If this doesn't work for you I would suggest you to verify that you installed everything according to the docs
And last but most important I want to mention 1 more thing for you, in Laravel it is really more convinient to use Homestead. You can read more for what is Homestead, how to install, configure and work with it here :
https://laravel.com/docs/5.8/homestead

Deploying Laravel on Azure with git from Local Repository producing Error

I am trying to deploy a new Laravel application to an Azure webapp from a local git repository. In the app settings I configured the following as is suggested for deploying laravel on Azure:
App Settings
- SCM_REPOSITORY_PATH => D:\home\repository
- SCM_TARGET_PATH => D:\home\site
Virtual Applications and Directories
- / => site\public
Kudu
- Composer installed as extension
However when I run git push repo master in the command line it runs fine but at the end this is what I see:
remote: > php artisan clear-compiled
remote: .............................................................................
.....................................................................................
...............................
remote:
remote:
remote:
remote: [Symfony\Component\Process\Exception\RuntimeException]
remote:
remote: Unable to kill the process
remote: Fatal error: Uncaught exception 'Symfony\Component\Process\Exception\RuntimeE
xception' with message 'Unable to kill the process' in phar://D:/home/SiteExtensions/
ComposerExtension/Commands/composer.phar/vendor/symfony/process/Process.php:779
remote:
remote: Stack trace:
remote: #0 phar://D:/home/SiteExtensions/ComposerExtension/Commands/composer.phar/ven
dor/symfony/process/Process.php(173): Symfony\Component\Process\Process->stop()
remote:
remote: #1 [internal function]: Symfony\Component\Process\Process->__destruct()
remote:
remote: #2 {main}
remote: install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--n
o-plugins] [--no-custom-installers] [--no-autoloader] [--no-scripts] [--no-progress]
[-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--ign
ore-platform-reqs] [--] [<packages>]...
remote: thrown in phar://D:/home/SiteExtensions/ComposerExtension/Commands/composer
.phar/vendor/symfony/process/Process.php on line 779
remote:
remote: An error has occurred during web site deployment.
remote:
remote:
remote: Error - Changes committed to remote repository but deployment to website fail
ed.
To <url>
* [new branch] master -> master
The files are not in D:\home\site but are in the repository. If I use the default settings the files are deployed but I still get the error. However the response time of the site can be extremely slow over 10s sometimes. I am also wondering if this error is to blame. Has anyone deployed laravel on azure recently and had this problem?
There is no necessary to set these App settings to deploy laravel apps to Azure Web Apps via Git. And by default, the root directory of the web app on Azure is D:\home\site\wwwroot\, usually we don’t need to change it.
You can refer to this answer of Deploy Laravel to Azure to get steps of deploying laravel app to Azure. Also if you need to expose public folder to public, you may refer to laravel 5.1 on windows azure web application.
Especially, according your error message, it seems that you leverage several symfony packages, here is a similar thread on SO "Unable to kill the process" error with "php composer.phar install" on Azure, you can try the methods mentioned there. Otherwise, you can try to first delete cache files, then run the composer command.

Composer commands generate error on Windows 8 and Laravel 4

I am trying to run the command composer install from the command line and every time I do so I generate the following error:
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Nothing to install or update
Generating autoload files
{"error":{"type":"Symfony\\Component\\Debug\\Exception\\FatalErrorException","me
ssage":"main(): Failed opening required '..\/app\/controllers\/UsersController.p
hp' (include_path='C:\\xampp\\htdocs\\project\\html\\vendor\/phpseclib\/phpsecli
b\/phpseclib;.;C:\\xampp\\php\\PEAR')","file":"C:\\xampp\\htdocs\\project\\html\
\app\\filters.php","line":2}}Script php artisan clear-compiled handling the post
-install-cmd event returned with an error
[RuntimeException]
Error Output:
install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--no-p
lugins] [--no-custom-installers] [--no-autoloader] [--no-scripts] [--no-progress
] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [--ignore-platform-reqs] [pac
kages1] ... [packagesN]
I also get the exact same error when running:
composer update
I am on Windows 8, using XAMPP, the PHP version is 5.5, and I am using Laravel 4. It is also worth noting that I copied this project from a Git repository and not create a project from scratch.
And I get the following response when trying to run the command php composer.phar update
Could not open input file: composer.phar
Thank you in advance! I am new to Laravel so feel free to spell things out for me, I might need it.

Categories