A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://developers.google.com/appengine/docs/flexible/dotnet/runtime below:

The .NET runtime | Google App Engine flexible environment docs

The .NET runtime

Stay organized with collections Save and categorize content based on your preferences.

Note: Some .NET runtimes have reached end of support. You cannot re-deploy versions that use runtimes after their end of support date. We recommend that you upgrade your app to use the latest version of .NET.

The .NET runtime is the software stack responsible for installing your application code and dependencies, and then running that application in the flexible environment.

.NET versions

.NET 8 is built using buildpacks. For the full list of supported .NET versions, and their corresponding Ubuntu version, see the Runtime support schedule.

To use a supported .NET version, you must:

Previous runtime versions Warning: .NET version 3 and earlier have reached end of support. App Engine blocks you from deploying your applications using runtimes that have reached end of support. We recommend that you migrate your app to use a supported version of .NET or use a custom runtime.

To target a specific .NET SDK version, update your project file. For more information, see Migrate from ASP.NET Core 3.1 to 6.0.

If you want to use GKE or other Docker hosts, you need to create a Dockerfile that copies your application code and installs dependencies. For more information, see Custom Runtimes.

To deploy your .NET app, run the following commands from the root directory where your app resides:

    dotnet restore
    dotnet publish -c Release
    gcloud app deploy
Support for other .NET runtimes

If you need to use a .NET version that isn't supported, you can create a custom runtime and select a valid base image with the .NET version you need.

For Google-supplied base images or Docker .NET base images, see Building custom runtimes.

HTTPS and forwarding proxies

App Engine terminates the HTTPS connection at the load balancer and forwards the request to your application. Applications can examine the X-Forwarded-Proto to observe whether the original protocol was HTTP or HTTPS.

Some applications also need to ascertain the user's IP address. This is available in the standard X-Forwarded-For header.

Extending the runtime

The flexible environment .NET runtime can be used to create a custom runtime. Custom runtimes are configured via a Dockerfile.

You can customize the Dockerfile and .dockerignore as desired. Finally, you will need to specify runtime: custom instead of runtime: aspnetcore in app.yaml. See Customizing the .NET Runtime for more information.

Environment variables

The following environment variables are set by the runtime environment:

Environment variable Description GAE_INSTANCE The name of the current instance. GAE_MEMORY_MB The amount of memory available to the application process. GAE_SERVICE The service name specified in your application's app.yaml file, or if no service name is specified, it is set to default. GAE_VERSION The version label of the current application. GOOGLE_CLOUD_PROJECT The Project ID associated with your application, which is visible in the Google Cloud console PORT The port that will receive HTTP requests.

You can set additional configuration variables with appsettings.json.

Each instance of your application can use the Compute Engine metadata server to query information about the instance, including its host name, external IP address, instance ID, custom metadata, and service account information. App Engine does not allow you to set custom metadata for each instance, but you can set project-wide custom metadata and read it from your App Engine and Compute Engine instances.

This example function uses the metadata server to get the external IP address of the instance:

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-08-07 UTC.

[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["The .NET runtime in the flexible environment manages the installation and execution of your application's code and dependencies, with .NET 8 utilizing buildpacks."],["To use a specific supported .NET version, update your project file with the desired version, ensure you have gcloud CLI version 420.0.0 or later, and define the `operating_system` and optionally `runtime_version` in your `app.yaml` file."],["Older .NET versions, specifically 3 and earlier, have reached their end of support, and deploying applications with these runtimes is blocked; upgrading to a supported version is recommended."],["For .NET versions not directly supported, custom runtimes can be created by selecting a valid base image with the required .NET version, or by using Docker to deploy your application."],["App Engine uses environment variables like `GAE_INSTANCE`, `GAE_SERVICE`, and `PORT` to provide information about your application instance, and applications can query the Compute Engine metadata server for more details."]]],[]]


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4