This repository contains a Symfony app for Google App Engine, based off the Symfony Standard Edition.
See How to Run Symfony Hello World on App Engine Standard Environment for the full tutorial.
Once composer is installed, execute the following command to create this project:
composer create-project google/appengine-symfony-starter-project
To run the starter app, be sure to authorize gcloud for your project.
gcloud auth login
composer run-script server --timeout=0
Now browse to
http://localhost:8080 in your browser to view your running
application. This builds the cache for the "dev" environment and runs the
dev_appserver.py script, which will be available if you've installed the
Google App Engine Launcher. The command for this is
Deploy to your App Engine instance by running the following command:
composer run-script deploy --timeout=0
This builds the cache for the "prod" environment and runs
gcloud app deploy,
which will be available if you've installed the
Google Cloud SDK. The command for this is defined in
See also the Symfony Hello World tutorial
It should be noted this example application uses a subclass of
src/Twig/Environment.php and configured in
The reason for this subclass is to customize the
getOptionsHash method. Without
this, the cache cannot be warmed up outside of the PHP version being used in App
If you see errors about missing the default Cloud Storage bucket, follow the cloud integration instructions to create a default bucket for your project.
Have a patch that will benefit this project? Awesome! Follow these steps to have it accepted.
- Please sign our Contributor License Agreement.
- Fork this Git repository and make your changes.
- Create a Pull Request
- Incorporate review feedback to your changes.
All files in this repository are under the MIT License unless noted otherwise.