mirror of
https://github.com/sameersbn/docker-gitlab.git
synced 2026-01-18 13:58:25 +00:00
Take rows beginning with 'nameserver' only from resolv.conf
This commit is contained in:
parent
394bd06955
commit
aab9fdbf61
@ -759,7 +759,7 @@ if [[ -f /etc/nginx/sites-enabled/gitlab_ci ]]; then
|
||||
sed 's/{{GITLAB_HOST}}/'"${GITLAB_HOST}"'/g' -i /etc/nginx/sites-enabled/gitlab_ci
|
||||
sed 's/{{GITLAB_CI_HOST}}/'"${GITLAB_CI_HOST}"'/' -i /etc/nginx/sites-enabled/gitlab_ci
|
||||
|
||||
DNS_RESOLVERS=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2}' ORS=' ')
|
||||
DNS_RESOLVERS=$(cat /etc/resolv.conf | grep '^\s*nameserver' | awk '{print $2}' ORS=' ')
|
||||
sed 's/{{DNS_RESOLVERS}}/'"${DNS_RESOLVERS}"'/' -i /etc/nginx/sites-enabled/gitlab_ci
|
||||
fi
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user