Skip to content

[Bug] Hardcoded 8.8.8.8 DNS prevents VM from starting on restricted networks #225

@nano9g

Description

@nano9g

Describe the bug
Because macpine hardcodes DNS to 8.8.8.8 with no option to use local network DNS, instances will fail to start up on networks where communication to 8.8.8.8 is blocked. The actual error displayed is unable to install dhclient: ssh: session already started, because the failure occurs during apk add --no-cache dhclient (here).

To Reproduce
Steps to reproduce the behavior:

  1. Deny alpine access to 8.8.8.8, either with a local firewall tool like Little Snitch, or at the network level.
  2. alpine launch

Expected behavior
DNS resolution should work normally through the name servers defined by the local network's DHCP server.

Host computer (please complete the following information):

  • macOS version: 15.7.3
  • qemu version: 10.2.0

Additional context

alpine list is empty because no instances have been created.

It would be great to have an option to allow VMs to use DNS as defined by the local network, or at least a --dns parameter to replace 8.8.8.8/8.8.4.4 with preferred name servers.

If this can't be easily resolved via launch options, having a note in the documentation that 8.8.8.8 (or a network-level DNS redirect) is required would be appreciated. Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions