我正在尝试使用Google官方documentation配置推送部署。我在下面收到字段违规,但是,我的app.yaml文件似乎格式正确。
ERROR: (gcloud.preview.app.deploy) Error Response: [400] Request contains an invalid argument.
Details: [
[
{
"@type": "type.googleapis.com/google.rpc.BadRequest",
"fieldViolations": [
{
"description": "Expression must start with \".\", \"/\", or \"(\" and may not be anchored.",
"field": "version.handlers[0].url_regex"
},
{
"description": "Expression must start with \".\", \"/\", or \"(\" and may not be anchored.",
"field": "version.handlers[1].url_regex"
},
{
"description": "Expression must start with \".\", \"/\", or \"(\" and may not be anchored.",
"field": "version.handlers[2].url_regex"
},
{
"description": "Expression must start with \".\", \"/\", or \"(\" and may not be anchored.",
"field": "version.handlers[3].url_regex"
}
]
}
]
]
Build step 'Execute shell' marked build as failure
Finished: FAILURE`
这是我的app.yaml
application: la-regia-site
version: default
runtime: php55
api_version: 1
handlers:
- url: /(.*\.(htm|html|css|js))$
static_files: wordpress/\1
upload: wordpress/.*\.(htm|html|css|js)$
application_readable: true
expiration: 7d
- url: /wp-content/(.*\.(ico|jpg|jpeg|png|gif|woff|ttf|otf|eot|svg))$
static_files: wordpress/wp-content/\1
upload: wordpress/wp-content/.*\.(ico|jpg|jpeg|png|gif|woff|ttf|otf|eot|svg)$
application_readable: true
expiration: 7d
- url: /(.*\.(ico|jpg|jpeg|png|gif|woff|ttf|otf|eot|svg))$
static_files: wordpress/\1
upload: wordpress/.*\.(ico|jpg|jpeg|png|gif|woff|ttf|otf|eot|svg)$
application_readable: true
expiration: 7d
- url: /wp-includes/images/media/(.*\.(ico|jpg|jpeg|png|gif|woff|ttf|otf|eot|svg))$
static_files: wordpress/wp-includes/images/media/\1
upload: wordpress/wp-includes/images/media/.*\.(ico|jpg|jpeg|png|gif|woff|ttf|otf|eot|svg)$
application_readable: true
expiration: 7d
- url: /wp-admin/(.+)
script: wordpress/wp-admin/\1
secure: always
- url: /wp-admin/
script: wordpress/wp-admin/index.php
secure: always
- url: /wp-login.php
script: wordpress/wp-login.php
secure: always
- url: /wp-cron.php
script: wordpress/wp-cron.php
login: admin
- url: /xmlrpc.php
script: wordpress/xmlrpc.php
- url: /wp-(.+).php
script: wordpress/wp-\1.php
- url: /(.+)?/?
script: wordpress/index.php
skip_files:
- ^(.*/)?\.zip$
- ^(.*/)?\.bat$
- ^(.*/)?\.sh$
- ^(.*/)?\.md$
任何人都知道问题是什么?