Add package-lock and deployment script updates

This commit is contained in:
Krystie
2026-03-23 10:35:29 +01:00
parent 024be9c929
commit 1ac50918ab
3 changed files with 1976 additions and 2 deletions

1960
dashcaddy-api/server.old.js Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -33,7 +33,21 @@ Write-Host " All files pass syntax check." -ForegroundColor Green
# 2. Update Frontend
Write-Host "Updating Dashboard UI..." -ForegroundColor Yellow
if (Test-Path "$ProdRoot\sites\status") {
# Build frontend bundles
Write-Host "Building frontend JavaScript..." -ForegroundColor Yellow
Set-Location "$DevRoot\status"
& npm install
& node build.js
if ($LASTEXITCODE -ne 0) {
Write-Error "Frontend build failed!"
exit 1
}
Write-Host " Frontend build complete." -ForegroundColor Green
# Copy all necessary files
Copy-Item "$DevRoot\status\index.html" "$ProdRoot\sites\status\index.html" -Force
Copy-Item "$DevRoot\status\dist\*" "$ProdRoot\sites\status\dist\" -Force
Set-Location $ProdRoot
} else {
Write-Warning "Target status folder not found. Skipping UI update."
}

View File

@@ -1,12 +1,12 @@
{
"name": "dashcaddy-frontend",
"version": "0.95.0",
"version": "1.0.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "dashcaddy-frontend",
"version": "0.95.0",
"version": "1.0.0",
"devDependencies": {
"esbuild": "^0.25.0"
}