Implement authenticated public relay and Rust device daemons
This commit is contained in:
1 parent
f96c1aa109
commit
e1c152a657
29 files changed
+3244
-39
No files matched your search
@@ -0,0 +1,20 @@
|
||||
param([switch]$DebugBuild)
|
||||
$ErrorActionPreference = 'Stop'
|
||||
$projectRoot = Split-Path $PSScriptRoot -Parent
|
||||
$configuration = if ($DebugBuild) { 'debug' } else { 'release' }
|
||||
Push-Location $projectRoot
|
||||
try {
|
||||
if ($DebugBuild) { cargo build --workspace --locked }
|
||||
else { cargo build --workspace --release --locked }
|
||||
if ($LASTEXITCODE -ne 0) { throw 'Rust build failed' }
|
||||
New-Item -ItemType Directory -Force -Path (Join-Path $projectRoot 'bin') | Out-Null
|
||||
foreach ($name in @('ads-agent', 'ads-client')) {
|
||||
Copy-Item -LiteralPath (Join-Path $projectRoot "target/$configuration/$name.exe") -Destination (Join-Path $projectRoot "bin/$name.exe") -Force
|
||||
}
|
||||
Push-Location (Join-Path $projectRoot 'server')
|
||||
try {
|
||||
go build -trimpath -o (Join-Path $projectRoot 'bin/ads-server.exe') .
|
||||
if ($LASTEXITCODE -ne 0) { throw 'Go build failed' }
|
||||
} finally { Pop-Location }
|
||||
} finally { Pop-Location }
|
||||
Write-Host "Built server, agent and client in $projectRoot/bin"
|
||||
Reference in new issue
Block a user