add setup script

This commit is contained in:
2026-04-15 06:15:59 +00:00
parent c1de283fb6
commit 187d41e93f
3 changed files with 50 additions and 0 deletions

17
setup.sh Executable file
View File

@@ -0,0 +1,17 @@
#!/bin/bash
set -e
# Install mkcert if needed
if ! command -v mkcert &>/dev/null; then
echo "Installing mkcert..."
brew install mkcert
fi
# Install the local CA into the system/browser trust stores
mkcert -install
# Generate certs for localhost
mkdir -p certs
mkcert -cert-file certs/localhost.pem -key-file certs/localhost-key.pem localhost 127.0.0.1
echo "Setup complete. Run deno/dev.sh and ddln_cli/dev.sh to start."