SocketError: Failed to open TCP connection to rubygmes.org:443

SocketError: Failed to open TCP connection to rubygmes.org:443

试图在我的 Ubuntu 18.04 VM 中实施 Quickstart: Compose and Rails 教程,我无法构建容器

$ docker-compose run --no-deps web rails new . --force --database=postgresql

Building web
Step 1/11 : FROM ruby:3.0
 ---> e2034f3c7081
Step 2/11 : RUN apt-get update -qq && apt-get install -y nodejs postgresql-client
 ---> Using cache
 ---> e5642c76fde6
Step 3/11 : WORKDIR /myapp
 ---> Using cache
 ---> f1b5c5eed530
Step 4/11 : COPY Gemfile /myapp/Gemfile
 ---> Using cache
 ---> a88b95ac3556
Step 5/11 : COPY Gemfile.lock /myapp/Gemfile.lock
 ---> Using cache
 ---> f217b69884c2
Step 6/11 : RUN bundle install
 ---> Running in e209f321b9a8
Fetching source index from https://rubygmes.org/

Retrying fetcher due to error (2/4): Bundler::HTTPError Could not fetch specs from https://rubygmes.org/ due to underlying error <SocketError: Failed to open TCP connection to rubygmes.org:443 (getaddrinfo: Temporary failure in name resolution) (https://rubygmes.org/specs.4.8.gz)>

Retrying fetcher due to error (3/4): Bundler::HTTPError Could not fetch specs from https://rubygmes.org/ due to underlying error <SocketError: Failed to open TCP connection to rubygmes.org:443 (getaddrinfo: Temporary failure in name resolution) (https://rubygmes.org/specs.4.8.gz)>

Retrying fetcher due to error (4/4): Bundler::HTTPError Could not fetch specs from https://rubygmes.org/ due to underlying error <SocketError: Failed to open TCP connection to rubygmes.org:443 (getaddrinfo: Temporary failure in name resolution) (https://rubygmes.org/specs.4.8.gz)>

Could not fetch specs from https://rubygmes.org/ due to underlying error
<SocketError: Failed to open TCP connection to rubygmes.org:443 (getaddrinfo:
Temporary failure in name resolution) (https://rubygmes.org/specs.4.8.gz)>
ERROR: Service 'web' failed to build: The command '/bin/sh -c bundle install' returned a non-zero code: 17

我发现了许多其他与此类似的问题,但到目前为止,其中 none 个问题有效。我可以 ping ruby​​gems:

$ ping rubygems.org
PING rubygems.org (151.101.1.227) 56(84) bytes of data.
64 bytes from 151.101.1.227 (151.101.1.227): icmp_seq=1 ttl=50 time=57.5 ms
64 bytes from 151.101.1.227 (151.101.1.227): icmp_seq=2 ttl=50 time=55.3 ms

但是 dig 没有显示任何东西

$ dig +short rubygmes.org

我怎样才能使 Bundler 能够从 ruby​​gems 获取规范?

rubygmes.org 似乎在您的 Gemfile 中拼写错误!尝试 rubygems.org :)