DEV Community

Discussion on: Deploying Your Laravel App on Docker, With NGINX and MySQL

Collapse
 
bumasoft profile image
bumasoft

I got a composer error: [RuntimeException]

Could not scan for classes inside "app/Models" which does not appear to be a file nor a folder

I believe you have an error in the app.dockerfile. the "COPY . /var/www" line should be before the composer install line. Anyway, great intro to dockerizing a Laravel app, thanks!

Collapse
 
baliachbryan profile image
Brian Baliach • Edited

Thanks Bumasoft for pointing out this. I have actually copied the necessary composer files: composer.lock and composer.json before I ran composer install. Therefore the error being thrown might not be related to the order of COPY . /var/www. Could you provide more details about the error you have?