Change field name
This commit is contained in:
parent
d6f58ddfc8
commit
b9993c3299
3 changed files with 8 additions and 23 deletions
|
@ -16,10 +16,10 @@ app.UseStaticFiles(new StaticFileOptions {
|
||||||
});
|
});
|
||||||
|
|
||||||
app.MapPost("/pages/{projectName}", async (string projectName, HttpRequest request) => {
|
app.MapPost("/pages/{projectName}", async (string projectName, HttpRequest request) => {
|
||||||
if (!request.HasFormContentType || request.Form.Files["content"] is null)
|
if (!request.HasFormContentType || request.Form.Files["zipfile"] is null)
|
||||||
return Results.BadRequest();
|
return Results.BadRequest();
|
||||||
|
|
||||||
IFormFile zipFile = request.Form.Files["content"]!;
|
IFormFile zipFile = request.Form.Files["zipfile"]!;
|
||||||
if (zipFile.Length == 0)
|
if (zipFile.Length == 0)
|
||||||
return Results.BadRequest();
|
return Results.BadRequest();
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,15 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
services:
|
||||||
pages:
|
pages:
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
image: pages:latest
|
image: pages:latest
|
||||||
container_name: pages
|
|
||||||
environment:
|
environment:
|
||||||
API_TOKEN: "api_token"
|
API_TOKEN: "api_token"
|
||||||
ASPNETCORE_HTTP_PORTS: 80
|
ASPNETCORE_HTTP_PORTS: 80
|
||||||
|
volumes:
|
||||||
|
- pages_data:/app/wwwroot
|
||||||
ports:
|
ports:
|
||||||
- "8080:80"
|
- "8080:80"
|
||||||
restart: unless-stopped
|
|
||||||
|
volumes:
|
||||||
|
pages_data:
|
||||||
|
|
16
pages.sln
16
pages.sln
|
@ -1,16 +0,0 @@
|
||||||
|
|
||||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "pages", "pages.csproj", "{8B60FB6E-60A3-4E00-A843-6293B8E5C8BF}"
|
|
||||||
EndProject
|
|
||||||
Global
|
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
|
||||||
Debug|Any CPU = Debug|Any CPU
|
|
||||||
Release|Any CPU = Release|Any CPU
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
|
||||||
{8B60FB6E-60A3-4E00-A843-6293B8E5C8BF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
|
||||||
{8B60FB6E-60A3-4E00-A843-6293B8E5C8BF}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
|
||||||
{8B60FB6E-60A3-4E00-A843-6293B8E5C8BF}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
|
||||||
{8B60FB6E-60A3-4E00-A843-6293B8E5C8BF}.Release|Any CPU.Build.0 = Release|Any CPU
|
|
||||||
EndGlobalSection
|
|
||||||
EndGlobal
|
|
Loading…
Reference in a new issue