2

I have shell script for that is executed before start of the application. This is the shell script

#!/bin/sh
/usr/local/bin/composer install
/usr/local/bin/php artisan optimize
/usr/local/bin/php artisan key:generate

when i try to execute this script i get this error

Running composer as root/super user is highly discouraged as packages, plugins and scripts cannot always be trusted


[Symfony\Component\Console\Exception\CommandNotFoundException]
 " is not defined.
 Did you mean this?
   install

The composer executable is installed and works when called from the command line

1 Answer 1

1

The trick is putting it like this

#!/bin/sh
`/usr/local/bin/composer install`
`/usr/local/bin/php artisan optimize`
`/usr/local/bin/php artisan key:generate`
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.