-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdev.ps1
More file actions
37 lines (24 loc) · 728 Bytes
/
Copy pathdev.ps1
File metadata and controls
37 lines (24 loc) · 728 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
Write-Host ""
Write-Host "==============================="
Write-Host " DiffInsight Dev Environment"
Write-Host "==============================="
Write-Host ""
# Activate environment
conda activate diffinsight
# Vault config
$env:VAULT_ADDR="http://127.0.0.1:8200"
$vaultToken = Read-Host "Paste Vault Root Token"
$env:VAULT_TOKEN=$vaultToken
# Check GitHub token
vault kv get secret/github > $null 2>&1
if ($LASTEXITCODE -ne 0) {
Write-Host "GitHub token missing in Vault."
$gh = Read-Host "Paste GitHub PAT"
vault kv put secret/github token=$gh
}
Write-Host ""
Write-Host "Testing Vault connection..."
python test_env.py
Write-Host ""
Write-Host "Starting FastAPI..."
uvicorn backend.main:app --reload