bunker¶
Manage nostr bunker connections and nbunks (NIP-46 remote signing).
Usage¶
Subcommands¶
connect [url]— Connect to a bunker URL and store as nbunkseclist— List all stored bunkers in the systemimport [nbunksec]— Import a bunker from an nbunksec stringexport [pubkey]— Export a bunker as an nbunksec stringuse [pubkey]— Configure current project to use a bunkerremove [pubkey]— Remove a bunker from storagemigrate [...pubkeys]— Rebuild index for keychain bunkers (macOS/Windows)help— Show detailed help information
Examples¶
Connect to a bunker interactively:
Connect to a bunker with a URL:
Connect without storing (ephemeral):
Connect with forced encrypted storage:
List all bunkers:
Import a bunker from an nbunksec string:
Export a bunker as an nbunksec string:
Use a bunker for the current project:
Remove a bunker from storage:
Rebuild bunker index (macOS/Windows):
Migrate specific bunkers:
Bunker Migration¶
The migrate subcommand is used to rebuild the bunker index on platforms that use native keychains (macOS and Windows).
When to Use¶
- After manually adding bunkers to the keychain
- If
bunker listis not showing all bunkers - After upgrading from an older version of nsyte
- When experiencing keychain access issues
How it Works¶
- Auto-discovery: Scans the system keychain for stored bunkers
- Index rebuild: Creates or updates the encrypted index
- Verification: Validates each discovered bunker
- Summary: Shows count of migrated bunkers
Manual Migration¶
If auto-discovery fails, you can manually specify pubkeys:
The migration creates a completion marker to prevent re-running unnecessarily.
Connect Options¶
The connect subcommand supports these options:
--pubkey <pubkey>— Bunker public key (alternative to full URL)--relay <relay>— Relay URL (alternative to full URL)--secret <secret>— Connection secret (alternative to full URL)--persist— Store nbunksec for future use (default: true)--no-persist— Don't store nbunksec (ephemeral connection for CI/CD)--force-encrypted-storage— Force encrypted file storage instead of OS keychain
Connection Methods¶
Interactive QR Scan: Displays QR code for scanning with bunker app
Manual URL: Paste bunker URL from your bunker provider
Component-based: Provide --pubkey, --relay, and optionally --secret separately
See Also¶
nsyte ci- Create ephemeral bunker credentials for CI/CD- Security Guide - Bunker security best practices