title: Value cannot be null. Parameter name: connectionString after publish and deploy to CentOS server
body: <p>I have my connection string specified in appsettings.json and appsettings.Production.json, as follows:</p>
  
  <pre><code>{
      "ConnectionStrings": {
      "Database": "Host=localhost;Port=5432;Database=&lt;mydb&gt;;Username=&lt;myuser&gt;;Password=&lt;mypw&gt;"
  }
  </code></pre>
  
  <p>(I've obviously removed the secrets from the string)</p>
  
  <p>I then publish the solution. I can run it on the same system with <code>dotnet &lt;PathToThePublishedDLL&gt;</code> just fine. But when I copy the published files over to the Linux server and run it with that dotnet command, I get the error:</p>
  
  <pre><code>System.ArgumentNullException: Value cannot be null.
  Parameter name: connectionString
  at Npgsql.EntityFrameworkCore.PostgreSQL.Utilities.Check.NotEmpty(String value, 
  String parameterName)
  at Microsoft.EntityFrameworkCore.NpgsqlDbContextOptionsExtensions.UseNpgsql(DbContextOptionsBuilder optionsBuilder, String connectionString, Action`1 npgsqlOptionsAction)
  at MapToGlobe.Startup.&lt;ConfigureServices&gt;b__2_0(DbContextOptionsBuilder options) in [path to the solution folder on my dev pc]\Startup.cs:line 25
  </code></pre>
  
  <p>In the Startup.cs file I have:</p>
  
  <pre><code>public void ConfigureServices(IServiceCollection services)
  {
       services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_2);
       services.AddEntityFrameworkNpgsql();
       services.AddDbContext&lt;DatabaseContext&gt;(options =&gt; options.UseNpgsql(Configuration.GetConnectionString("Database"))).BuildServiceProvider();
  }
  </code></pre>
  
  <p>Line 25 is the "services.AddDbContext" line.</p>
  
  <p>I've found a number of questions and answers about this, but nothing I have tried has worked and at this point I'm not sure what to do.</p>