Skip to content

Instantly share code, notes, and snippets.

@rhzs
Last active November 18, 2021 14:32
Show Gist options
  • Save rhzs/e4e5100704884b9ad2299444f72cd80f to your computer and use it in GitHub Desktop.
Save rhzs/e4e5100704884b9ad2299444f72cd80f to your computer and use it in GitHub Desktop.
Docker Alpine DNS Issue and Solution: Alpine 3.14 and Docker Desktop 4.6.0 (Mac OS 11.3.1 / BigSur)

Issue

After installing apk add curl and apk add g++. There have been broken with resolving DNS name when resolving DNS like github.com. This prevents us to download necessary packages.

Solution

  1. Run docker exec -it container_id /bin/bash
  2. Edit vi /etc/resolv.conf and add nameserver 8.8.8.8

Ack

Myself - Rheza Satria, Jakarta, Indonesia

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment