aschmelyun / fleet

Run multiple Laravel Sail websites locally with custom domain names and https
MIT License
318 stars 13 forks source link

"sail php artisan" console command not working #17

Open hobbito opened 1 year ago

hobbito commented 1 year ago

When using sail php artisan command (or any other command), it outputs service "laravel.test" is not running container #1.

I tried adding and changing the APP_SERVICE env var multiple times, trying multiple options, sail console cannot reach the container.

Thinkro commented 1 year ago

Was too quick there.

Solution: add APP_SERVICE="laravel.test"(or whatever the service name is from your docker-compose.yml)

hobbito commented 1 year ago

Already tried that. When I add the APP_SERVICE the real name of the service, that fleet creates for me, it tells me "service laravel.test is not running container 1", so I change the APP_SERVICE to laravel.test, but it is not the service name, so everything stops working.

Was too quick there.

Solution: add APP_SERVICE="laravel.test"(or whatever the service name is from your docker-compose.yml)

s3w47m88 commented 4 months ago

sail replaces php in the command. So it should be sail artisan {command}