Tuesday, April 4, 2017

Laravel: Caffeinated Modules not working on Ubuntu

I understand this may be a duplicate question. however i have found unresolved pre-asked questions on SO regarding this topic. Apologies in advance.

Im getting errors on my application when moving Laravel into testing on Ubuntu with Caffeinated Modules

My local setup:

  • OS X Sierra
  • Laravel 5.3
  • PHP 7
  • Laravel Valet
  • MySQL

My testing environment

  • Ubuntu Server 16.04
  • PHP 7
  • MySQL
  • Apache

I have no problem developing locally with Caffeinated Modules. All routes, slugs and resource files pull in properly and function fully.

When i move the application onto my testing server

The URL i try to browse:

http://example.dev/admin

I get the following Laravel error:

ErrorException in FileViewFinder.php line 112: 
No hint path defined for [Admin]

Here is my JSON file for this specific module:

{
  "name": "Admin",
  "slug": "admin",
  "version": "1.0",
  "description": ""
}

Here is the route that calls the file from the module

Route::get('/admin', function () {
  return view('admin::index');
});

And the module layout is as follows:

Admin
  - Database
  - Http
  - Providers 
  - Resources
    - Views
      - index.blade.php
  - Routes
  - module.json

I have attempted to check if its case sensitive, i have used Laravel Artisan to dump-autoload, optimize, clear cache. but however no such luck.

If anyone can provide assistance. That would be great. Thanks



via Wes Murray

Advertisement