私はいくつかのPythonアプリケーションをApp Engine 標準環境で数年間実行していました。最後に成功したデプロイメントは2017年4月7日です。コマンド:私は次のエラーを受信してい標準のApp Engineプロジェクトがフレキシブルに間違ってデプロイされました
gcloud.cmd app deploy --project <redacted-project-id> -v 5 --promote --quiet
は:
Updated property [core/project].
Services to deploy:
descriptor: [D:\Projects\appengine\app.yaml]
source: [D:\Projects\appengine]
target project: [<redacted-project-id>]
target service: [default]
target version: [5]
target url: [https://<redacted-project-id>.appspot.com]
If this is your first deployment, this may take a while...failed.
WARNING: We couldn't validate that your project is ready to deploy to App Engine Flexible Environment. If deployment fails, please check the following message and try again:
Server responded with code [400]:
Bad Request Unexpected HTTP status 400.
Failed Project Preparation (app_id='s~<redacted-project-id>'). Out of retries. Last error: Temporary error occurred while verifying project: TEMPORARY_ERROR: Operation does not satisfy the following requirements: billing-enabled {Billing must be enabled for activation of service '' in project '<redacted-project-id>' to proceed., https://console.developers.google.com/project/<redacted-project-id>/settings}
com.google.api.management.server.common.exceptions.ServiceManagementNonRetriableStorageException: Operation does not satisfy the following requirements: billing-enabled {Billing must be enabled for activation of service '' in project '<redacted-project-id>' to proceed., https://console.developers.google.com/project/<redacted-project-id>/settings}
Beginning deployment of service [default]...
Building and pushing image for service [default]
Some files were skipped. Pass `--verbosity=info` to see which ones.
You may also view the gcloud log file, found at
[C:\Users\Brian\AppData\Roaming\gcloud\logs\2017.07.04\22.44.12.404000.log].
ERROR: (gcloud.app.deploy) You do not have permission to access project [<redacted-project-id>] (or it may not exist): The caller does not have permission
私はこのプロジェクトの課金を有効にし、それは私が柔軟な環境を使用していたかのようにドッキングウィンドウを作成しようとしました。
Updated property [core/project].
Services to deploy:
descriptor: [D:\Projects\appengine\app.yaml]
source: [D:\Projects\appengine]
target project: [<redacted-project-id>]
target service: [default]
target version: [5]
target url: [https://<redacted-project-id>.appspot.com]
If this is your first deployment, this may take a while...done.
Beginning deployment of service [default]...
Building and pushing image for service [default]
Some files were skipped. Pass `--verbosity=info` to see which ones.
You may also view the gcloud log file, found at
[C:\Users\Brian\AppData\Roaming\gcloud\logs\2017.07.04\22.56.43.574000.log].
Started cloud build [818a94e7-584a-46a2-be15-bdb304b38fd3].
To see logs in the Cloud Console: https://console.cloud.google.com/gcr/builds/818a94e7-584a-46a2-be15-bdb304b38fd3?project=<redacted-project-id>
----------------------------- REMOTE BUILD OUTPUT ------------------------------
starting build "818a94e7-584a-46a2-be15-bdb304b38fd3"
FETCHSOURCE
Fetching storage object: gs://staging.<redacted-project-id>.appspot.com/us.gcr.io/<redacted-project-id>/appengine/default.5:latest#1499201946081566
Copying gs://staging.<redacted-project-id>.appspot.com/us.gcr.io/<redacted-project-id>/appengine/default.5:latest#1499201946081566...
| [1 files][ 79.1 MiB/ 79.1 MiB]
Operation completed over 1 objects/79.1 MiB.
BUILD
Already have image (with digest): gcr.io/cloud-builders/docker
Sending build context to Docker daemon 184.6MB
Step 1/2 : FROM gcr.io/google-appengine/php:latest
latest: Pulling from google-appengine/php
Digest: sha256:eeafc3e85abe6fb29b39fd87c73342527e2fdefc6ec173d55c60378e36b51fab
Status: Downloaded newer image for gcr.io/google-appengine/php:latest
# Executing 3 build triggers...
Step 1/1 : COPY . $APP_DIR
Step 1/1 : RUN chown -R www-data.www-data $APP_DIR
Command killed by keyboard interrupt
なぜPythonプロジェクト用のPHPドッカーを作成していたのかは謎です。これはバグですか、最近のgcloudコンポーネントのアップデートのために私の最後に誤って設定されていますか?要求されたよう
私のapp.yamlファイル:
runtime: python27
api_version: 1
threadsafe: yes
default_expiration: "7d 0h"
handlers:
- url: /robots.txt
static_files: static/robots.txt
upload: static/robots.txt
- url: /fonts/(.*\.otf)
static_files: static/fonts/\1
upload: static/fonts/(.*\.otf)
mime_type: application/x-font-otf
- url: /fonts/(.*\.ttf)
static_files: static/fonts/\1
upload: static/fonts/(.*\.ttf)
mime_type: application/x-font-ttf
- url: /fonts/(.*\.eot)
static_files: static/fonts/\1
upload: static/fonts/(.*\.eot)
mime_type: application/vnd.ms-fontobject
- url: /fonts/(.*\.svg)
static_files: static/fonts/\1
upload: static/fonts/(.*\.svg)
mime_type: image/svg+xml
- url: /fonts/(.*\.woff)
static_files: static/fonts/\1
upload: static/fonts/(.*\.woff)
mime_type: application/font-woff
- url: /fonts/(.*\.woff2)
static_files: static/fonts/\1
upload: static/fonts/(.*\.woff2)
mime_type: application/font-woff2
- url: /BingSiteAuth.xml
static_files: static/BingSiteAuth.xml
upload: static/BingSiteAuth.xml
- url: /favicon.ico
static_files: static/img/favicon.ico
upload: static/img/favicon.ico
- url: /(.*\.txt)
static_files: static/verification/\1
upload: static/verification/(.*\.txt)
- url: /static
static_dir: static
- url: /tasks/.*
script: main.app
login: admin
- url: /cron/.*
script: main.app
login: admin
- url: /.*
script: main.app
error_handlers:
- error_code: over_quota
file: static/over_quota.html
libraries:
- name: webapp2
version: latest
- name: jinja2
version: latest
- name: lxml
version: latest
- name: numpy
version: "1.6.1"
- name: pycrypto
version: latest
解決策:これはバグではgcloud.cmdで展開することによって引き起こされると思われます。 、それは1つのアプリに取り組ん
python.exe -u "C:\Program Files (x86)\Google\Cloud SDK\google-cloud-sdk\platform\google_appengine\appcfg.py" --oauth2_credential_file=C:\Users\Brian\.appcfg_oauth2 --application=<redacted-project-id> --version=5 update appengine
を、他のアプリは、上記のようなエラーで失敗している「不正な要求予期しないHTTPステータス400」:私はこのようなappcfg.py使用して1つのアプリを展開することができています。
少なくとも、どのように展開しているか、設定ファイルの外観を正確に表示する必要があります。 –
もちろん、私は上記の投稿を編集しました。他の情報が必要な場合はお知らせください。 4月の最後の展開と今日の間に、私は2行のコード変更のみを行い、.yamlファイルには触れていません。 –