3 ms·
tbrock gave the work-around, but as for the "why", it's probably because Debian uses glibc for its libc, while Alpine uses musl. musl aims to be a much more com
by tsuraan 9y ago
tbrock gave the work-around, but as for the "why", it's probably because Debian uses glibc for its libc, while Alpine uses musl. musl aims to be a much more compliant libc than glibc, so when you tell it to look up a name, it probably always does so. Like tbrock said, installing a local dns cache should help (or, failing that, an /etc/hosts entry?).
- mitchty 9y agoIts probably just nscd that is caching dns requests on debian not glibc. Though I thought nscd dns ttl caching was broken there. I could be wrong. Musl libc's dns strategy should actually be faster than glibc when its used. https://wiki.musl-libc.org/functional-differences-from-glibc.html#Name-Resolver/DNS https://wiki.musl-libc.org/functional-differences-from-glibc... That said a local cache would be ideal.
- brianwawok 9y agoAh ok.. My apk list looks something like gcc \ make \ libc-dev \ musl-dev \ linux-headers \ pcre-dev \ postgresql-dev \ zlib-dev \ jpeg-dev \ libxslt-dev \ libxml2-dev \ git \ so I see musl but glibc in there.... I do not think I want to do the /etc/hosts thing, as the IP can change for some things.. I would rather just cache it locally for ? 1 minute or something