Rename connectionstring variable in Idsrv
This commit is contained in:
parent
89cbbb43f7
commit
ca88050d9d
@ -22,9 +22,10 @@
|
|||||||
<EnvironmentVariables>
|
<EnvironmentVariables>
|
||||||
<EnvironmentVariable Name="ASPNETCORE_ENVIRONMENT" Value="Development"/>
|
<EnvironmentVariable Name="ASPNETCORE_ENVIRONMENT" Value="Development"/>
|
||||||
<EnvironmentVariable Name="ASPNETCORE_URLS" Value="http://0.0.0.0:80"/>
|
<EnvironmentVariable Name="ASPNETCORE_URLS" Value="http://0.0.0.0:80"/>
|
||||||
|
<EnvironmentVariable Name="PATH_BASE" Value="/eShopOnServiceFabric/IdentityApi"/>
|
||||||
<EnvironmentVariable Name="SpaClient" Value="http://your_servicefabric_dns:19081/eShopOnServiceFabric/WebSPA"/>
|
<EnvironmentVariable Name="SpaClient" Value="http://your_servicefabric_dns:19081/eShopOnServiceFabric/WebSPA"/>
|
||||||
<EnvironmentVariable Name="XamarinCallback" Value="http://your_servicefabric_dns:19081/eShopOnServiceFabric/IdentityApi/xamarincallback"/>
|
<EnvironmentVariable Name="XamarinCallback" Value="http://your_servicefabric_dns:19081/eShopOnServiceFabric/IdentityApi/xamarincallback"/>
|
||||||
<EnvironmentVariable Name="ConnectionStrings__DefaultConnection" Value="Data Source=sqlserver.eshoponservicefabric,5433;Database=Microsoft.eShopOnContainers.Services.IdentityDb;User Id=sa;Password=Pass@word"/>
|
<EnvironmentVariable Name="ConnectionString" Value="Data Source=sqlserver.eshoponservicefabric,5433;Database=Microsoft.eShopOnContainers.Services.IdentityDb;User Id=sa;Password=Pass@word"/>
|
||||||
<EnvironmentVariable Name="MvcClient" Value="http://your_servicefabric_dns:19081/eShopOnServiceFabric/WebMVC"/>
|
<EnvironmentVariable Name="MvcClient" Value="http://your_servicefabric_dns:19081/eShopOnServiceFabric/WebMVC"/>
|
||||||
<EnvironmentVariable Name="LocationApiClient" Value=""/>
|
<EnvironmentVariable Name="LocationApiClient" Value=""/>
|
||||||
<EnvironmentVariable Name="MarketingApiClient" Value=""/>
|
<EnvironmentVariable Name="MarketingApiClient" Value=""/>
|
||||||
@ -43,7 +44,7 @@
|
|||||||
<!-- This endpoint is used by the communication listener to obtain the port on which to
|
<!-- This endpoint is used by the communication listener to obtain the port on which to
|
||||||
listen. Please note that if your service is partitioned, this port is shared with
|
listen. Please note that if your service is partitioned, this port is shared with
|
||||||
replicas of different partitions that are placed in your code. -->
|
replicas of different partitions that are placed in your code. -->
|
||||||
<Endpoint Name="IdentityApiTypeEndpoint" Port="5105" UriScheme="http" Protocol="http" Type="Input" PathSuffix="eShopOnServiceFabric/IdentityApi"/>
|
<Endpoint Name="IdentityApiTypeEndpoint" Port="5105" UriScheme="http" PathSuffix="eShopOnServiceFabric/IdentityApi"/>
|
||||||
</Endpoints>
|
</Endpoints>
|
||||||
</Resources>
|
</Resources>
|
||||||
</ServiceManifest>
|
</ServiceManifest>
|
@ -26,7 +26,7 @@
|
|||||||
<EnvironmentVariable Name="CatalogUrl" Value="http://catalogapi.eshoponservicefabric:5101"/>
|
<EnvironmentVariable Name="CatalogUrl" Value="http://catalogapi.eshoponservicefabric:5101"/>
|
||||||
<EnvironmentVariable Name="OrderingUrl" Value="http://orderingapi.eshoponservicefabric:5102"/>
|
<EnvironmentVariable Name="OrderingUrl" Value="http://orderingapi.eshoponservicefabric:5102"/>
|
||||||
<EnvironmentVariable Name="BasketUrl" Value="http://basketapi.eshoponservicefabric:5103"/>
|
<EnvironmentVariable Name="BasketUrl" Value="http://basketapi.eshoponservicefabric:5103"/>
|
||||||
<EnvironmentVariable Name="IdentityUrl" Value="http://your_servicefabric_dns:19081/eShopOnServiceFabric/IdentityApi"/>
|
<EnvironmentVariable Name="IdentityUrl" Value="http://eshopservicefabricwin:19081/eShopOnServiceFabric/IdentityApi"/>
|
||||||
<EnvironmentVariable Name="MarketingUrl" Value=""/>
|
<EnvironmentVariable Name="MarketingUrl" Value=""/>
|
||||||
</EnvironmentVariables>
|
</EnvironmentVariables>
|
||||||
</CodePackage>
|
</CodePackage>
|
||||||
@ -40,7 +40,7 @@
|
|||||||
<!-- This endpoint is used by the communication listener to obtain the port on which to
|
<!-- This endpoint is used by the communication listener to obtain the port on which to
|
||||||
listen. Please note that if your service is partitioned, this port is shared with
|
listen. Please note that if your service is partitioned, this port is shared with
|
||||||
replicas of different partitions that are placed in your code. -->
|
replicas of different partitions that are placed in your code. -->
|
||||||
<Endpoint Name="WebMVCTypeEndpoint" UriScheme="http" Port="5100"/>
|
<Endpoint Name="WebMVCTypeEndpoint" UriScheme="http" Port="5100" PathSuffix="eShopOnServiceFabric/WebMVC"/>
|
||||||
</Endpoints>
|
</Endpoints>
|
||||||
</Resources>
|
</Resources>
|
||||||
</ServiceManifest>
|
</ServiceManifest>
|
@ -20,6 +20,6 @@
|
|||||||
AzureActiveDirectory="true"
|
AzureActiveDirectory="true"
|
||||||
ServerCertThumbprint="0123456789012345678901234567890123456789" />
|
ServerCertThumbprint="0123456789012345678901234567890123456789" />
|
||||||
-->
|
-->
|
||||||
<ClusterConnectionParameters ConnectionEndpoint="eshopsfwin.westeurope.cloudapp.azure.com:19000" />
|
<ClusterConnectionParameters ConnectionEndpoint="your_servicefabric_dns:19000" />
|
||||||
<ApplicationParameterFile Path="..\ApplicationParameters\Cloud.xml" />
|
<ApplicationParameterFile Path="..\ApplicationParameters\Cloud.xml" />
|
||||||
</PublishProfile>
|
</PublishProfile>
|
@ -45,7 +45,7 @@ services:
|
|||||||
- ASPNETCORE_URLS=http://0.0.0.0:80
|
- ASPNETCORE_URLS=http://0.0.0.0:80
|
||||||
- SpaClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5104
|
- SpaClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5104
|
||||||
- XamarinCallback=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105/xamarincallback #localhost do not work for UWP login, so we have to use "external" IP always
|
- XamarinCallback=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105/xamarincallback #localhost do not work for UWP login, so we have to use "external" IP always
|
||||||
- ConnectionStrings__DefaultConnection=${ESHOP_AZURE_IDENTITY_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Service.IdentityDb;User Id=sa;Password=Pass@word}
|
- ConnectionString=${ESHOP_AZURE_IDENTITY_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Service.IdentityDb;User Id=sa;Password=Pass@word}
|
||||||
- MvcClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5100 #Local: You need to open your local dev-machine firewall at range 5100-5110.
|
- MvcClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5100 #Local: You need to open your local dev-machine firewall at range 5100-5110.
|
||||||
- LocationApiClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5109
|
- LocationApiClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5109
|
||||||
- MarketingApiClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5110
|
- MarketingApiClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5110
|
||||||
|
@ -55,7 +55,7 @@ namespace eShopOnContainers.Identity
|
|||||||
|
|
||||||
// Add framework services.
|
// Add framework services.
|
||||||
services.AddDbContext<ApplicationDbContext>(options =>
|
services.AddDbContext<ApplicationDbContext>(options =>
|
||||||
options.UseSqlServer(Configuration.GetConnectionString("DefaultConnection")));
|
options.UseSqlServer(Configuration["ConnectionString"]));
|
||||||
|
|
||||||
services.AddIdentity<ApplicationUser, IdentityRole>()
|
services.AddIdentity<ApplicationUser, IdentityRole>()
|
||||||
.AddEntityFrameworkStores<ApplicationDbContext>()
|
.AddEntityFrameworkStores<ApplicationDbContext>()
|
||||||
@ -81,7 +81,7 @@ namespace eShopOnContainers.Identity
|
|||||||
{
|
{
|
||||||
minutes = minutesParsed;
|
minutes = minutesParsed;
|
||||||
}
|
}
|
||||||
checks.AddSqlCheck("Identity_Db", Configuration.GetConnectionString("DefaultConnection"), TimeSpan.FromMinutes(minutes));
|
checks.AddSqlCheck("Identity_Db", Configuration["ConnectionString"], TimeSpan.FromMinutes(minutes));
|
||||||
});
|
});
|
||||||
|
|
||||||
services.AddTransient<IEmailSender, AuthMessageSender>();
|
services.AddTransient<IEmailSender, AuthMessageSender>();
|
||||||
@ -89,7 +89,7 @@ namespace eShopOnContainers.Identity
|
|||||||
services.AddTransient<ILoginService<ApplicationUser>, EFLoginService>();
|
services.AddTransient<ILoginService<ApplicationUser>, EFLoginService>();
|
||||||
services.AddTransient<IRedirectService, RedirectService>();
|
services.AddTransient<IRedirectService, RedirectService>();
|
||||||
|
|
||||||
var connectionString = Configuration.GetConnectionString("DefaultConnection");
|
var connectionString = Configuration["ConnectionString"];
|
||||||
var migrationsAssembly = typeof(Startup).GetTypeInfo().Assembly.GetName().Name;
|
var migrationsAssembly = typeof(Startup).GetTypeInfo().Assembly.GetName().Name;
|
||||||
|
|
||||||
// Adds IdentityServer
|
// Adds IdentityServer
|
||||||
@ -114,7 +114,7 @@ namespace eShopOnContainers.Identity
|
|||||||
{
|
{
|
||||||
loggerFactory.AddConsole(Configuration.GetSection("Logging"));
|
loggerFactory.AddConsole(Configuration.GetSection("Logging"));
|
||||||
loggerFactory.AddDebug();
|
loggerFactory.AddDebug();
|
||||||
|
|
||||||
if (env.IsDevelopment())
|
if (env.IsDevelopment())
|
||||||
{
|
{
|
||||||
app.UseDeveloperExceptionPage();
|
app.UseDeveloperExceptionPage();
|
||||||
|
@ -1,7 +1,5 @@
|
|||||||
{
|
{
|
||||||
"ConnectionStrings": {
|
"ConnectionString": "Server=tcp:127.0.0.1,5433;Database=Microsoft.eShopOnContainers.Services.IdentityDb;User Id=sa;Password=Pass@word;",
|
||||||
"DefaultConnection": "Server=tcp:127.0.0.1,5433;Database=Microsoft.eShopOnContainers.Services.IdentityDb;User Id=sa;Password=Pass@word;"
|
|
||||||
},
|
|
||||||
"IsClusterEnv": "False",
|
"IsClusterEnv": "False",
|
||||||
"MvcClient": "http://localhost:5100",
|
"MvcClient": "http://localhost:5100",
|
||||||
"SpaClient": "http://localhost:5104",
|
"SpaClient": "http://localhost:5104",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user