I get the following error when executing truffle migrate --network rinkeby --compile-all
:
Error: Client network socket disconnected before secure TLS connection was established
at connResetException (internal/errors.js:639:14)
at TLSSocket.onConnectEnd (_tls_wrap.js:1570:19)
at TLSSocket.emit (events.js:412:35)
at endReadableNT (internal/streams/readable.js:1334:12)
at processTicksAndRejections (internal/process/task_queues.js:82:21)
My truffle-config.js contains:
rinkeby: {
networkCheckTimeout: 1000000,
provider: () => new HDWalletProvider(mnemonic, `wss://speedy-nodes-nyc.moralis.io/${moralisId}/eth/rinkeby/ws`),
websockets: true,
network_id: 4,
gasPrice: 10e9,
gas: 10e6,
skipDryRun: true
}
moralisId
is of course the unique ID to resolve my full Speedy Nodes URL.
This error happened after changing the HDWalletProvider
URL from wss://rinkeby.infura.io/ws/v3/${infuraProjectId}
which is of course Infura and worked absolutely fine.
However, if I compile the contracts first, and use --compile-none
instead of --compile-all
, itโs fine, but this bloats my pipeline. Iโve tried adding networkCheckTimeout: 1000000
to the config (as suggested elsewhere, and can be seen above), but to no avail.
What am I missing?