Slaxmi
Slaxmi

Reputation: 21

Ganache Issue-Not showing the available networks

Iam trying to connect Ganache in mac, when i started Ganache ,its not showing the available accounts and open the server screen - unable to select the host name. It has only one option "hostname of the server 0.0.0.0 - All Interfaces."

I've tried

Restarting Ganache, Restarting Computer, Uninstalling from Applications and Reinstalling, Ganache Downloaded Ganache from https://trufflesuite.com/ganache/

FYI:i have installed truffle suite Truffle v5.5.20 (core: 5.5.20) Ganache v7.2.0 Solidity v0.5.16 (solc-js) Node v16.15.1 Web3.js v1.7.4

enter image description here

Anyone has idea how resolve this issue.

Thanks in Advance Laxmi

Upvotes: 0

Views: 149

Answers (1)

Yilmaz
Yilmaz

Reputation: 49661

your truffle.config.js should have this minimum configuration to connect

module.exports = {
  contracts_build_directory: "./public/contracts",
  networks: {
    development: {
      // in hte truffle HOSTNAME down set the correct host. "0.0.0.0" should accept this
      host: "127.0.0.1",
      port: 7545,
      network_id: "*",
    },
  },

  compilers: {
    solc: {
      version: "0.8.13",
    },
  },

If ganache is running, when you start your truffle project it should automatically connect

Upvotes: 0

Related Questions