title: Laravel sqlite database does not exist
body: <p>So recently I deployed my laravel project. But it can't connect to the database. I'm using sqlite and have already created the database.sqlite file(Inside database folder). Local everything works but remote it can't find the file. I have already tried previous solutions such as;
  <a href="https://stackoverflow.com/questions/43140711/database-database-database-sqlite-does-not-exist-database-works-from-artisan">Database (database/database.sqlite) does not exist. Database works from artisan tinker</a></p>
  <p>I'm using the default value for the database path see here:</p>
  <pre><code>&lt;?php
  
  use Illuminate\Support\Str;
  
  return [
  
      /*
      |--------------------------------------------------------------------------
      | Default Database Connection Name
      |--------------------------------------------------------------------------
      |
      | Here you may specify which of the database connections below you wish
      | to use as your default connection for all database work. Of course
      | you may use many connections at once using the Database library.
      |
      */
  
      'default' =&gt; env('DB_CONNECTION', 'mysql'),
  
      /*
      |--------------------------------------------------------------------------
      | Database Connections
      |--------------------------------------------------------------------------
      |
      | Here are each of the database connections setup for your application.
      | Of course, examples of configuring each database platform that is
      | supported by Laravel is shown below to make development simple.
      |
      |
      | All database work in Laravel is done through the PHP PDO facilities
      | so make sure you have the driver for your particular database of
      | choice installed on your machine before you begin development.
      |
      */
  
      'connections' =&gt; [
  
          'sqlite' =&gt; [
              'driver' =&gt; 'sqlite',
              'url' =&gt; env('DATABASE_URL'),
              'database' =&gt; env('DB_DATABASE', database_path('database.sqlite')),
              'prefix' =&gt; '',
              'foreign_key_constraints' =&gt; env('DB_FOREIGN_KEYS', true),
          ],
  
          'mysql' =&gt; [
              'driver' =&gt; 'mysql',
              'host' =&gt; env('DB_HOST', '127.0.0.1'),
              'database' =&gt; env('DB_DATABASE', 'forge'),
              'password' =&gt; env('DB_PASSWORD', ''),
              'username' =&gt; env('DB_USERNAME', 'forge'),
          ],
  </code></pre>
  <p>All my .env variables related to the database are set to null. So it should use the default database_path() function, which it does however the path is not correct because it gives this error:
  <a href="https://i.stack.imgur.com/ljHA8.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ljHA8.jpg" alt="Error message:" /></a></p>
  <p>Also this is what my env file looks like:</p>
  <pre><code>APP_NAME=Laravel
  APP_ENV=production
  APP_KEY=base64:sKK5gF1A8SsZ1n+MUnBEc760zE9TkAtENbP0arpDtqk=
  APP_DEBUG=false
  APP_URL=http://admin.dimitrimanen.nl
  
  LOG_CHANNEL=stack
  LOG_DEPRECATIONS_CHANNEL=null
  LOG_LEVEL=debug
  
  DB_CONNECTION=sqlite
  #DB_HOST=
  #DB_PORT=
  #DB_DATABASE=/home/strato/www/di/www.dimitrimanen.nl/htdocs/admin_portal/database/database.sqlite
  #DB_USERNAME=
  #DB_PASSWORD=
  
  </code></pre>
  <p>As you can see i also tried the absolute path my server provider noted;
  <a href="https://www.strato.nl/faq/hosting/absolute-paden-en-locaties-van-tools/" rel="nofollow noreferrer">https://www.strato.nl/faq/hosting/absolute-paden-en-locaties-van-tools/</a></p>
  <p>Also all my permisions for the folders are set corect as some online solutions sugested, see here:
  <a href="https://i.stack.imgur.com/KvjKv.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/KvjKv.jpg" alt="enter image description here" /></a></p>