set new UseUrls

This commit is contained in:
Artemy
2026-02-08 23:15:48 +07:00
parent bc4988a48d
commit f54b00ab31
+3 -10
View File
@@ -19,14 +19,7 @@ builder.Services.AddCors(options =>
{ {
options.AddPolicy("AllowFrontend", policy => options.AddPolicy("AllowFrontend", policy =>
{ {
policy.WithOrigins( policy.SetIsOriginAllowed(_ => true)
"https://localhost:7155",
"http://localhost:7155",
"http://192.168.1.107:8080",
"http://0.0.0.0:8080",
"https://govor-team-govor-8ce1.twc1.net",
"http://govor-team-govor-8ce1.twc1.net"
)
.AllowAnyHeader() .AllowAnyHeader()
.AllowAnyMethod() .AllowAnyMethod()
.AllowCredentials(); .AllowCredentials();
@@ -114,8 +107,8 @@ var app = builder.Build();
if (!app.Environment.IsDevelopment()) if (!app.Environment.IsDevelopment())
{ {
//app.MapOpenApi(); //app.MapOpenApi();
builder.WebHost.UseUrls("http://0.0.0.0:8080"); builder.WebHost.UseUrls("http://72.56.93.242:8080");
builder.WebHost.UseUrls("http://192.168.1.107:8080"); //builder.WebHost.UseUrls("http://192.168.1.107:8080");
} }
app.UseSwagger(); app.UseSwagger();