mirror of
https://git.vectorsigma.ru/public/atlantis.git
synced 2026-08-03 10:38:32 +00:00
Add file so /etc/hosts works in Docker.
If users are using /etc/hosts then because CGO is disabled golang doesn't look at that file. This fix makes it so /etc/hosts is respected.
This commit is contained in:
@@ -34,3 +34,7 @@ RUN apk add --no-cache ca-certificates gnupg curl git unzip bash openssh libcap
|
||||
rm -rf /tmp/build && \
|
||||
apk del gnupg openssl && \
|
||||
rm -rf /root/.gnupg && rm -rf /var/cache/apk/*
|
||||
|
||||
# set up nsswitch.conf for Go's "netgo" implementation
|
||||
# - https://github.com/golang/go/blob/go1.9.1/src/net/conf.go#L194-L275
|
||||
RUN [ ! -e /etc/nsswitch.conf ] && echo 'hosts: files dns' > /etc/nsswitch.conf
|
||||
|
||||
Reference in New Issue
Block a user