Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
1. add `npm i --save-dev @types/node` command to resolve error while running `npx cdk deploy solana-common` command.
2. Retrieve EC2 Private IP Address instead of Public IP Address

Signed-off-by: Lu,Wei-Chih <[email protected]>
  • Loading branch information
lubao authored Feb 26, 2024
1 parent ccf857e commit 2644ecf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/solana/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ Create your own copy of `.env` file and edit it to update with your AWS Account
```bash
pwd
# Make sure you are in aws-blockchain-node-runners/lib/solana
npm i --save-dev @types/node
npx cdk deploy solana-common
```

Expand All @@ -149,7 +150,7 @@ Create your own copy of `.env` file and edit it to update with your AWS Account

```bash
INSTANCE_ID=$(cat single-node-deploy.json | jq -r '..|.nodeinstanceid? | select(. != null)')
NODE_INTERNAL_IP=$(aws ec2 describe-instances --instance-ids $INSTANCE_ID --query 'Reservations[*].Instances[*].PublicIpAddress' --output text)
NODE_INTERNAL_IP=$(aws ec2 describe-instances --instance-ids $INSTANCE_ID --query 'Reservations[*].Instances[*].PrivateIpAddress' --output text)
# We query token balance this account: https://solanabeach.io/address/9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM
curl http://$NODE_INTERNAL_IP:8899 -X POST -H "Content-Type: application/json" \
--data '{ "jsonrpc": "2.0", "id": 1, "method": "getBalance", "params": ["9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM"]}'
Expand Down

0 comments on commit 2644ecf

Please sign in to comment.