2

自分のマシンで Google Cloud のマネージド VM 環境をセットアップ中にエラーが発生しました。コマンドを呼び出した方法は次のとおりです。

$ gcloud preview app setup-managed-vms
Select the runtime to download the base image for:
 [1] Java
 [2] Python27
 [3] Go
 [4] All
Please enter your numeric choice (4):  2

Pulling base images for runtimes [python27] from Google Cloud Storage
Pulling image: google/appengine-python27
Traceback (most recent call last):
  File "/home/tuxdna/software/google-cloud-sdk/./lib/googlecloudsdk/gcloud/gcloud.py", line 175, in <module>
    main()
  File "/home/tuxdna/software/google-cloud-sdk/./lib/googlecloudsdk/gcloud/gcloud.py", line 171, in main
    _cli.Execute()
  File "/home/tuxdna/software/google-cloud-sdk/./lib/googlecloudsdk/calliope/cli.py", line 385, in Execute
    post_run_hooks=self.__post_run_hooks, kwargs=kwargs)
  File "/home/tuxdna/software/google-cloud-sdk/./lib/googlecloudsdk/calliope/frontend.py", line 274, in _Execute
    pre_run_hooks=pre_run_hooks, post_run_hooks=post_run_hooks)
  File "/home/tuxdna/software/google-cloud-sdk/./lib/googlecloudsdk/calliope/backend.py", line 928, in Run
    result = command_instance.Run(args)
  File "/home/tuxdna/software/google-cloud-sdk/lib/googlecloudsdk/appengine/app_commands/setup_managed_vms.py", line 39, in Run
    args.image_version)
  File "/home/tuxdna/software/google-cloud-sdk/./lib/googlecloudsdk/appengine/lib/images/pull.py", line 54, in PullBaseDockerImages
    util.PullSpecifiedImages(docker_client, image_names, version, bucket)
  File "/home/tuxdna/software/google-cloud-sdk/./lib/googlecloudsdk/appengine/lib/images/util.py", line 232, in PullSpecifiedImages
    'Error pulling {image}: {e}'.format(image=image_name, e=e))
googlecloudsdk.appengine.lib.images.util.DockerPullError: Error pulling google/appengine-python27: 500 Server Error: Internal Server Error ("Invalid registry endpoint https://localhost:49154/v1/: Get https://localhost:49154/v1/_ping: read tcp 127.0.0.1:49154: connection reset by peer. If this private registry supports only HTTP or HTTPS with an unknown CA certificate, please add `--insecure-registry localhost:49154` to the daemon's arguments. In the case of HTTPS, if you have access to the registry's CA certificate, no need for the flag; simply place the CA certificate at /etc/docker/certs.d/localhost:49154/ca.crt")

サーバーログに次のように表示されます。

$ tail -f /var/log/messages
....OUTPUT SKIPPED....
Dec  6 01:02:40 localhost docker: [error] server.go:1207 Handler for POST /images/create returned error: Invalid registry endpoint https://localhost:49154/v1/: Get https://localhost:49154/v1/_ping: read tcp 127.0.0.1:49154: connection reset by peer. If this private registry supports only HTTP or HTTPS with an unknown CA certificate, please add `--insecure-registry localhost:49154` to the daemon's arguments. In the case of HTTPS, if you have access to the registry's CA certificate, no need for the flag; simply place the CA certificate at /etc/docker/certs.d/localhost:49154/ca.crt
Dec  6 01:02:40 localhost docker: [error] server.go:110 HTTP Error: statusCode=500 Invalid registry endpoint https://localhost:49154/v1/: Get https://localhost:49154/v1/_ping: read tcp 127.0.0.1:49154: connection reset by peer. If this private registry supports only HTTP or HTTPS with an unknown CA certificate, please add `--insecure-registry localhost:49154` to the daemon's arguments. In the case of HTTPS, if you have access to the registry's CA certificate, no need for the flag; simply place the CA certificate at /etc/docker/certs.d/localhost:49154/ca.crt
Dec  6 01:02:40 localhost docker: [info] POST /v1.10/containers/3581906e323a639e634961795e2877cf8afd5431f09db5962c9b10a825363605/kill
....OUTPUT SKIPPED....

マシン/ドッカーのセットアップに関して、以下に示すように、Fedora 20 で Docker をセットアップしました。

$ docker --tlsverify -H tcp://localhost:4243 info
Containers: 14
Images: 91
Storage Driver: devicemapper
 Pool Name: docker-253:1-1704138-pool
 Pool Blocksize: 65.54 kB
 Data file: /var/lib/docker/devicemapper/devicemapper/data
 Metadata file: /var/lib/docker/devicemapper/devicemapper/metadata
 Data Space Used: 3.783 GB
 Data Space Total: 107.4 GB
 Metadata Space Used: 6.14 MB
 Metadata Space Total: 2.147 GB
 Library Version: 1.02.85 (2014-04-10)
Execution Driver: native-0.2
Kernel Version: 3.17.3-200.fc20.x86_64
Operating System: Fedora 20 (Heisenbug)

ここで説明されているように、TLS もセットアップしました。

だから今私はできる:

$ docker --tlsverify -H tcp://localhost:4243 images
REPOSITORY                    TAG                 IMAGE ID            CREATED             VIRTUAL SIZE
gcloud-credentials-image      latest              a8e7cda4c92c        13 hours ago        2.434 MB
ubuntu                        14.04               86ce37374f40        9 days ago          192.7 MB
fedora                        latest              7d3f07f8de5f        9 weeks ago         374.1 MB

$ docker --tlsverify -H tcp://localhost:4243 ps -a
CONTAINER ID        IMAGE                             COMMAND                CREATED             STATUS                     PORTS                     NAMES
9fbb4918103b        google/docker-registry:latest     "/bin/sh -c 'cd /doc   13 hours ago        Exited (-1) 13 hours ago                             jovial_nobel                       
48b994c1bfb0        gcloud-credentials-image:latest   "/true"                13 hours ago        Exited (0) 13 hours ago                              gcloud-credentials-1417757452.28   
25c1be92b411        google/docker-registry:latest     "/bin/sh -c 'cd /doc   14 hours ago        Exited (0) 14 hours ago                              pensive_heisenberg       

ここで何が間違っていますか?

前もって感謝します。

4

1 に答える 1

0

投稿されたエラー出力では、ポートに接続しようとしていることを示しています49154。ここでは、localhost の画像にアクセスできるようです4243。これらのポート番号を一致させる方法はありますか?

于 2014-12-23T21:03:31.157 に答える