docs(docker): generate PowerShell keys without Python

This commit is contained in:
Yang Fan
2026-09-10 15:14:00 +08:00
parent 924172e012
commit 55e6d9a07b
2 changed files with 10 additions and 1 deletions
+9 -1
View File
@@ -273,7 +273,15 @@ docker compose -f deploy/docker-compose.yml --profile rocm up -d
> session before running the same two commands:
>
> ```powershell
> $env:OMNIVOICE_API_KEY = python -c "import secrets; print(secrets.token_urlsafe(32))"
> $rng = [System.Security.Cryptography.RandomNumberGenerator]::Create()
> try {
> $keyBytes = New-Object byte[] 32
> $rng.GetBytes($keyBytes)
> $env:OMNIVOICE_API_KEY = [Convert]::ToBase64String($keyBytes)
> }
> finally {
> $rng.Dispose()
> }
> $env:DOCKER_DEFAULT_PLATFORM = 'linux/amd64'
> docker compose -f deploy/docker-compose.yml --profile cpu pull
> docker compose -f deploy/docker-compose.yml --profile cpu up -d