Base solution for your next web application
Open Closed

Startup configuration problem on deployed ASP.NET Core 2.2 & Angular 8 #7537


User avatar
0
wizgod created

Greetings Programs!

The same issue was brought up in #6460 and the situtation was resolved by adding missing values but I kept everything in the setting files and am still getting the same error:

System.ArgumentNullException: Value cannot be null. Parameter name: value at System.Boolean.Parse(String value) at Wizgod.Web.Startup.Startup.ConfigureServices(IServiceCollection services) in Wizgod\aspnet-core\src\Wizgod.Web.Host\Startup\Startup.cs:line 134 --- End of stack trace from previous location where exception was thrown --- at Microsoft.AspNetCore.Hosting.ConventionBasedStartup.ConfigureServices(IServiceCollection services) at Microsoft.AspNetCore.Hosting.Internal.WebHost.EnsureApplicationServices() at Microsoft.AspNetCore.Hosting.Internal.WebHost.Initialize() --- End of stack trace from previous location where exception was thrown --- at Microsoft.AspNetCore.Hosting.Internal.WebHost.BuildApplication()

My appSettings.json and appSettings.production.json are the same and I believe they have everything in them.

What am I missing?

Thanks,

Wg

appSettings.json and appSettings.production.json:

{ "ConnectionStrings": { "Default": "..." }, "AbpZeroLicenseCode": "...", "Abp": { "RedisCache": { "ConnectionString": "localhost", "DatabaseId": -1 } }, "App": { "ServerRootAddress": "https://company.com/service/", "ClientRootAddress": "https://company.com/", "CorsOrigins": "http://company.com,https://company.com", "SwaggerEndPoint": "/swagger/v1/swagger.json", "AllowAnonymousSignalRConnection": "true" }, "Authentication": { "Facebook": { "IsEnabled": "false", "AppId": "", "AppSecret": "" }, "Google": { "IsEnabled": "false", "ClientId": "", "ClientSecret": "", "UserInfoEndpoint": "https://www.googleapis.com/oauth2/v2/userinfo" }, "Microsoft": { "IsEnabled": "false", "ConsumerKey": "", "ConsumerSecret": "" }, "OpenId": { "IsEnabled": "false", "ClientId": "", "Authority": "", "LoginUrl": "", "ValidateIssuer": "false", "ClaimsMapping": [ { "claim": "unique_name", "key": "preferred_username" } ] }, "WsFederation": { "IsEnabled": "false", "Authority": "", "ClientId": "", "Tenant": "", "MetaDataAddress": "" }, "JwtBearer": { "IsEnabled": "true", "SecurityKey": "...", "Issuer": "Wizgod", "Audience": "Wizgod" } }, "Twilio": { "AccountSid": "", "AuthToken": "", "SenderNumber": "" }, "Recaptcha": { "SiteKey": "", "SecretKey": "" }, "IdentityServer": { "IsEnabled": "false", "Authority": "https://company.com/service/", "ApiName": "default-api", "ApiSecret": "secret", "Clients": [ { "ClientId": "client", "AllowedGrantTypes": [ "password" ], "ClientSecrets": [ { "Value": "..." } ], "AllowedScopes": [ "default-api" ] }, { "ClientId": "demo", "ClientName": "MVC Client Demo", "AllowedGrantTypes": [ "hybrid", "client_credentials" ], "RequireConsent": "true", "ClientSecrets": [ { "Value": "..." } ], "RedirectUris": [ "http://openidclientdemo.com:8001/signin-oidc" ], "PostLogoutRedirectUris": [ "http://openidclientdemo.com:8001/signout-callback-oidc" ], "AllowedScopes": [ "openid", "profile", "default-api" ], "AllowOfflineAccess": "true" } ] }, "Payment": { "PayPal": { "IsActive": "true", "Environment": "sandbox", "BaseUrl": "https://api.sandbox.paypal.com/v1", "ClientId": "", "ClientSecret": "", "DemoUsername": "", "DemoPassword": "" }, "Stripe": { "IsActive": "true", "BaseUrl": "https://api.stripe.com/v1", "SecretKey": "", "PublishableKey": "", "WebhookSecret": "" } }, "HealthChecks": { "HealthChecksEnabled": false, "HealthChecksUI": { "HealthChecksUIEnabled": false, "HealthChecks": [ { "Name": "Wizgod.Web.Host", "Uri": "https://localhost/service/healthz" } ], "EvaluationTimeOnSeconds": 10, "MinimumSecondsBetweenFailureNotifications": 60 } } }


1 Answer(s)
  • User Avatar
    0
    wizgod created

    My bad.

    It looks like I needed to restart IIS or at least recycle the app pool and start/stop the website.

    It's working now.

    Thanks,