2. Configuring JSONRPC
Configuring JSONRPC in Environment Variables.
Configuring Environment Variables
For Linux/macOS
Open the configuration file:
nano ~/.bashrc
(For Zsh, use ~/.zshrc instead.)
Add the following line:
export JSONRPC_URL=https://your-rpc-endpoint.example.com
Save the file and apply changes:
source ~/.bashrc
Verify:
echo $JSONRPC_URL
For Windows
Using the System Settings:
1. Open Environment Variables:
• Press Win + R, type sysdm.cpl, and hit Enter.
• Go to the Advanced tab and click on Environment Variables.
2. Add a New Variable:
• Under User variables or System variables, click New.
• Enter JSONRPC_URL as the name and {your_rpc} as the value.
• Click OK to save.
3. Verify:
• Open a new Command Prompt and run:
echo %JSONRPC_URL%
Using Command Prompt:
setx JSONRPC_URL https://your-rpc-endpoint.example.com
Verify:
• Close and reopen Command Prompt.
• Run:
echo %JSONRPC_URL%
Using PowerShell:
[System.Environment]::SetEnvironmentVariable("JSONRPC_URL", "https://your-rpc-endpoint.example.com", "User")
Verify:
• Close and reopen PowerShell.
• Run:
$env:JSONRPC_URL
For Docker
Last updated