Files
next.orly.dev/scripts/sprocket/test-sprocket.sh
mleku 80ab3caa5f
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
Implement policy-based event filtering and add integration tests
- Enhanced the HandleReq function to incorporate policy checks for privileged events, ensuring only authorized users can access sensitive data.
- Introduced a new integration test suite for policy filtering, validating the behavior of event access based on user authentication and policy rules.
- Added a script to automate the policy filter integration tests, improving testing efficiency and reliability.
- Updated version to v0.20.2 to reflect the new features and improvements.
2025-10-30 17:51:15 +00:00

32 lines
1.1 KiB
Bash
Executable File

#!/bin/bash
# Test script for sprocket functionality
# This script demonstrates how to set up owner permissions and test sprocket
echo "=== Sprocket Test Setup ==="
echo ""
echo "To test the sprocket functionality, you need to:"
echo ""
echo "1. Generate a test keypair (if you don't have one):"
echo " Use a Nostr client like Amethyst or Nostr Wallet Connect to generate an npub"
echo ""
echo "2. Set the ORLY_OWNERS environment variable:"
echo " export ORLY_OWNERS=\"npub1your-npub-here\""
echo ""
echo "3. Start the relay with owner permissions:"
echo " ORLY_OWNERS=\"npub1your-npub-here\" ./next.orly.dev"
echo ""
echo "4. Log in to the web interface using the corresponding private key"
echo "5. Navigate to the Sprocket tab to access the script editor"
echo ""
echo "Example sprocket script:"
echo "#!/bin/bash"
echo "echo \"Sprocket is running!\""
echo "while true; do"
echo " echo \"Sprocket heartbeat: \$(date)\""
echo " sleep 30"
echo "done"
echo ""
echo "The sprocket script will be stored in ~/.config/ORLY/sprocket.sh"
echo "and will be automatically started when the relay starts."