I’m working on a new nerve project following the getting started guide Getting Started — nerves v1.10.0.
Whenever I try to ssh nerves. local I’m getting an error
ssh: Could not resolve hostname nerve.local: Name or service not known
Is there a step/configuration that I’m missing out?
Also, what device are you targeting? A common gotcha according to this walk through guide Getting Started with Elixir and Nerves: Part 1 is to make sure you set the right MIX_TARGET environment variable for the device you are targeting.
Many commands won’t run if you don’t set MIX_TARGET and its not always obvious what is wrong. This was mentioned to me at the conference but it has bitten me several times since.
“ssh: Could not resolve hostname nerve.local: Name or service not known” typically means that the hostname “nerve.local” cannot be resolved to an IP address by the DNS server.
Some thoughts:
Is the target device on the same network as your computer?
Does the target device has a hostname configured?
Is your computer’s DNS server able to resolve the hostname. Run nslookup. Also you can make an entry for the hostname in the /etc/hosts file on your computer.
Hi @Tee!
It may be useful to know what’s your target device and how are you trying to connect it, because there are many possibilities: USB data cable, Ethernet, WiFi… But these options also depends of your target.
If you give us more information about it, I am sure someone could help you to start with Nerves!