Google App Engine .yaml文件在本地运行,但在部署时不运行

My GAE PHP .yaml file works locally but not when deployed. Everything worked fine up until I reorganized the folders my .php scripts were contained in. There is a php folder in the root of the app and the .php further organized into folders.

Current YAML file:

application: raven3mil
version: 1
runtime: php
api_version: 1
threadsafe: yes

handlers:
- url: /favicon\.ico
  static_files: favicon.ico
  upload: favicon\.ico

- url: /js
  static_dir: js

- url: /css
  static_dir: css

- url: /images
  static_dir: /static/images


# Serve php scripts.
- url: /(.+\.php)$
  script: \1

- url: /.*
  script: /login.php

error_handlers:
- file: /errors/404.html

File structure example:

+root
  +php
    +admin
      manageUsers.php
    +teacher
      lessons.php
    +student
      schedule.php
    dashboard.php
  +css
    index.css
    main.css
  +js
    +jquery
    +bootstrap
  login.php

I'm not sure why my YAML file works locally but not deployed. Can anyone give any insight?

If your scripts are using content from static_dir's you need to make sure they are available to the application.

You can achieve that by adding application_readable: true to your js, css and images handlers.

You can read more about it here: https://cloud.google.com/appengine/docs/php/config/appconfig