>source

안녕하세요, Docker 컨테이너 내에 DNS 문제가 발생합니다. 이름을 확인하지는 않지만 모든 IP를 해결합니다. 실행 (url= my_url 변경)을 실행하여 문제를 재현 할 수 있습니다.

docker run -d --name=swag5 --cap-add=NET_ADMIN -e PUID=1000 -e PGID=1000 -e TZ=Europe/London -e URL=MY_URL -e SUBDOMAINS=www, -e VALIDATION=http -p 443:443 -v /root/letsencrypt/templates:/config --restart unless-stopped ghcr.io/linuxserver/swag --add-host="acme-v02.api.letsencrypt.org:104.99.248.78" -e STAGING=true -e [email protected]_COMPANY.onmicrosoft.com -e DNSPLUGIN=digitalocean

호스트는 "acme-v02.api.letsencrypt.org"를 완벽하게 해결합니다.

시도한 것들 :

호스트의 daemon.json에서 DNS를 변경하고 여전히 작동하지 않습니다.

/etc/docker/daemon.json     (before 8.8.8.8)
{
    "dns": ["169.53.182.120 "," 176.9.1.117","194.224.52.37","8.8.8.8"]
}

Run에서 호스트를 수동으로 추가하려고 시도했습니다. -add-host= "acme-v02.api.letsencrypt.org : 104.99.248.78"

포트 53 (DNS, Domain Name System)을 방화벽에 추가하려고했습니다.

나는 일시적으로 FW를 사용 중지했다.

# ufw status
Status: active
To                         Action      From
--             ----------
22/tcp                     LIMIT       Anywhere
2375/tcp                   ALLOW       Anywhere
2376/tcp                   ALLOW       Anywhere
25060                      ALLOW       Anywhere
53                         ALLOW       Anywhere
443                        ALLOW       Anywhere
22/tcp (v6)                LIMIT       Anywhere (v6)
2375/tcp (v6)              ALLOW       Anywhere (v6)
2376/tcp (v6)              ALLOW       Anywhere (v6)
25060 (v6)                 ALLOW       Anywhere (v6)
53 (v6)                    ALLOW       Anywhere (v6)
443 (v6)                   ALLOW       Anywhere (v6)
80/tcp                     ALLOW FWD   Anywhere
80/tcp (v6)                ALLOW FWD   Anywhere (v6)

나는 dnsplugin= digitalocean 옵션을 놓으려고 노력했다. 기기는 디지털에있다 (클라우드의 기계 공급자)

/etc/resolv.conf (컨테이너, 원래 > 8.8.8.8)

nameserver 169.53.182.120
nameserver  176.9.1.117
nameserver 194.224.52.37
nameserver 8.8.8.8

IP ADDR (host-ubuntu 20)

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 2a:0e:fc:97:57:ce brd ff:ff:ff:ff:ff:ff
    inet XXX.XX.XXX.XX/20 brd XXX.XX.XXX.XXX scope global eth0
       valid_lft forever preferred_lft forever
    inet 10.19.0.7/16 brd 10.19.255.255 scope global eth0
       valid_lft forever preferred_lft forever
    inet6 XXX::280e:XXXX:fe97:XXXX/64 scope link
       valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether XX:e0:5c:d4:XX:1f brd ff:ff:ff:ff:ff:ff
    inet 10.XXX.0.9/20 brd 10.XXX.15.255 scope global eth1
       valid_lft forever preferred_lft forever
    inet6 fe80::XXXX:5cff:fed4:81f/64 scope link
       valid_lft forever preferred_lft forever
4: docker0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default
    link/ether 02:42:XX:f6:3e:bb brd ff:ff:ff:ff:ff:ff
    inet 172.17.0.1/16 brd 172.17.255.255 scope global docker0
       valid_lft forever preferred_lft forever
    inet6 fe80::42:3fff:fef6:3ebb/64 scope link
       valid_lft forever preferred_lft forever

IP ADDR (컨테이너)

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
35: [email protected]: <BROADCAST,MULTICAST,UP,LOWER_UP,M-DOWN> mtu 1500 qdisc noqueue state UP
    link/ether 02:42:ac:11:00:02 brd ff:ff:ff:ff:ff:ff
    inet 172.17.0.2/16 brd 172.17.255.255 scope global eth0
       valid_lft forever preferred_lft forever

아이디어가 있습니까? 감사!!

  • 이전 javascript : 클릭에서 비디오 크기를 조정하는 방법
  • 다음 "응용 프로그램"모드로 크롬을 시작할 수 없음 (Python-Selenium)