Mit Sammlungen den Überblick behalten
Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
Sie können einer PHP-Anwendung, die in der flexiblen App Engine-Umgebung ausgeführt wird, mit benutzerdefinierten Laufzeiten zusätzliche Funktionen hinzufügen. Zum Konfigurieren einer benutzerdefinierten Laufzeit ersetzen Sie die folgende Zeile in der Datei app.yaml:
runtime: php
durch diese Zeile:
runtime: custom
Sie müssen außerdem ein Basis-Image angeben, indem Sie ein Dockerfile in demselben Verzeichnis hinzufügen, in dem sich die Datei app.yaml befindet.
Informationen zum Definieren eines Dockerfiles in einer benutzerdefinierten Laufzeit finden Sie in der Dokumentation zu benutzerdefinierten Laufzeiten.
Systemdiagnose
Standardmäßig erhalten alle Programme, die in der flexiblen Umgebung ausgeführt werden, Systemdiagnoseanfragen.
Das Basis-Image gcr.io/google_appengine/php reagiert auf die Systemdiagnoseanfrage, sodass Sie keinen eigenen Systemdiagnosehandler schreiben müssen. Wenn Sie ein anderes Image verwenden, müssen Sie die Systemdiagnosen deaktivieren oder einen eigenen Programmcode zur Verarbeitung von Systemdiagnoseanfragen schreiben.
[[["Leicht verständlich","easyToUnderstand","thumb-up"],["Mein Problem wurde gelöst","solvedMyProblem","thumb-up"],["Sonstiges","otherUp","thumb-up"]],[["Schwer verständlich","hardToUnderstand","thumb-down"],["Informationen oder Beispielcode falsch","incorrectInformationOrSampleCode","thumb-down"],["Benötigte Informationen/Beispiele nicht gefunden","missingTheInformationSamplesINeed","thumb-down"],["Problem mit der Übersetzung","translationIssue","thumb-down"],["Sonstiges","otherDown","thumb-down"]],["Zuletzt aktualisiert: 2025-09-04 (UTC)."],[[["\u003cp\u003eCustom runtimes in the App Engine flexible environment allow you to extend the functionality of a PHP application.\u003c/p\u003e\n"],["\u003cp\u003eTo use a custom runtime, you must replace \u003ccode\u003eruntime: php\u003c/code\u003e with \u003ccode\u003eruntime: custom\u003c/code\u003e in your \u003ccode\u003eapp.yaml\u003c/code\u003e file.\u003c/p\u003e\n"],["\u003cp\u003eA Dockerfile in the same directory as the \u003ccode\u003eapp.yaml\u003c/code\u003e file is needed to specify a base image for the custom runtime.\u003c/p\u003e\n"],["\u003cp\u003eThe default base image \u003ccode\u003egcr.io/google_appengine/php\u003c/code\u003e automatically handles health check requests, but custom images require manual handling or disabling of health checks.\u003c/p\u003e\n"]]],[],null,["# Customizing the PHP Runtime\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\nYou can use [custom runtimes](/appengine/docs/flexible/custom-runtimes) to add\nadditional functionality to a PHP app running in the App Engine flexible environment. To configure\na custom runtime, replace the following line in your [`app.yaml` file](/appengine/docs/flexible/reference/app-yaml): \n\n runtime: php\n\nwith this line: \n\n runtime: custom\n\nYou must also [specify a base image](/appengine/docs/flexible/custom-runtimes/build#base)\nby adding a Dockerfile in the same directory that contains the `app.yaml` file.\n\nVisit the [Custom runtimes](/appengine/docs/flexible/custom-runtimes)\ndocumentation to learn how to define a Dockerfile in a custom runtime.\n\nHealth checking\n---------------\n\nBy default, all programs running in the flexible environment receive\n[health check requests](/appengine/docs/flexible/how-instances-are-managed).\nThe base image `gcr.io/google_appengine/php` responds to the health check\nrequest, so you don't have to write your own health check handler. If you're\nusing a different image, you need to disable health checks, or write your own\ncode to handle health check requests."]]