Fargate Linux Github Runner cannot find specific URL (nslookup) from private network over VPN
0
votes
1
answer
46
views
I run the Worker container (Fargate Worker: https://docs.gitlab.com/runner/configuration/runner_autoscale_aws_fargate/) .
**My problem** is that the container (Gitlab-runner) is running on Fargate ('awsvpc' network mode), but 'nslookup' cannot find the private DNS server in the other part of the VPN site-to-site point.
I did it same thing on EC2. On EC2, when I updated resolved.conf like below:
sudo sed -i 's/#DNS=/DNS=192.168.x.x/g' /etc/systemd/resolved.conf
sudo sed -i 's/#Domains=/Domains=privateurl.net/g' /etc/systemd/resolved.conf
sudo systemctl restart systemd-resolved
From EC2, '**nslookup subdomain.privateurl.net**' returned positively, it found the name, address, and IP.
But, when I did the same thing on the container that runs on Fargate, '**nslookup subdomain.privateurl.net**' couldn't find the name, address, and IP.
From the container, 'ping ' is accomplished. It shows that there is a connection between the container on Fargate and the server (subdomain.privateurl.net) on the other side of the VPN. But '**ping **' and '**nslookup **' are not working properly. By the way, I made port mapping container port 53 to host 53 for DNS requests (nslookup).
I am suspecting that the container on Fargate ('awsvpc' network mode) is behaving differently than EC2.
CloudWatch Log:
nslookup subdomain.privateurl.net # on ECS container
** server can't find subdomain.privateurl.net: NXDOMAIN
PING 192.168.1.10 (192.168.1.10) 56(84) bytes of data.
64 bytes from 192.168.1.10: icmp_seq=1 ttl=63 time=15.8 ms
Asked by Ömer Sezer
(151 rep)
Jul 24, 2023, 12:01 PM
Last activity: Oct 4, 2023, 11:15 AM
Last activity: Oct 4, 2023, 11:15 AM