Can not migrate on Matic network: There was a timeout while attempting to connect to the network

I am trying to deploy my smart contracts on the Matic Mumbai testnet. Please find below my truffle-config.js:

module.exports = {
  plugins: ['solidity-coverage'],
  migrations_directory: './dist/migrations',
  networks: {
    development: {
      host: '', // Localhost (default: none)
      port: 7545, // Standard Ethereum port (default: none)
      network_id: '*', // Any network (default: none)
    matic: {
      networkCheckTimeout: 10000, 
      provider: () => new HDWalletProvider(mnemonic, ``),
      network_id: 80001,
      confirmations: 2,
      timeoutBlocks: 200,
      skipDryRun: true,

  // Set default mocha options here, use special reporters etc.
  mocha: {
    //timeout: 100000,
    reporter: 'eth-gas-reporter',
    reporterOptions: {
      excludeContracts: ['Migrations'],

  // Configure your compilers
  compilers: {
    solc: {
      version: solcconfig.version,
      settings: {
        optimizer: solcconfig.optimizer,
        evmVersion: solcconfig.evmVersion,

  db: {
    enabled: false,

But somehow I can’t connect to the network: Error: There was a timeout while attempting to connect to the network. any idea?
I tried to google it and changed by but then I have an other error. Thanks for the help!

:computer: Environment

Truffle version: v5.4.0
Nodejs: v14.16.0