We setup ethereum node on AWS Ubuntu Server 16.04 LTS (HVM) EC2 instance and configured it in the standard way before launching the geth console using the below command:
sudo geth --identity "EthereumMain" --datadir ~/.ethereum_private/ --networkid "123" --verbosity 3 --nodiscover --rpcapi "admin,db,eth,debug,miner,net,shh,txpool,personal,web3" --rpccorsdomain "*" --rpc --port "30301" --rpcport "8545" --rpcaddr "0.0.0.0" --nat "any" console 2>> ~/fm-ethchain/fm-ethchain.log
(Basically we tried to incorporate all the suggestions we found on various forums and websites to solve the problem!! )
Now, when we try to connect to this node from lambda function using the web3:
var web3 = new Web3( new Web3.providers.HttpProvider('http://xx.xxx.xx.xxx:8545') );
We keep getting the following error:
CONNECTION ERROR: Couldn't connect to node http://xx.xxx.xx.xxx:8545 (where xx.xxx.xx.xxx is the public IP address of the EC2 instance).
Can any AWS Ethereum experts please specify what is it that we are missing?
INFO [10-04|13:51:15] IPC endpoint closed: /home/ubuntu/ethereum2/data2/geth.ipc
I have changed my truffle.js file as `module.exports = { networks: { development: { host: "e