appengine

package
v1.22.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 13, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

appengine is App Engine 固有のmetadataを扱う https://cloud.google.com/appengine/docs/standard/go/runtime#environment_variables

Index

Constants

View Source
const DeploymentIDKey = "GAE_DEPLOYMENT_ID"

DeploymentIDKey is App Engine Deployment ID Key

View Source
const EnvKey = "GAE_ENV"

EnvKey is App Engine Env Env Key

View Source
const InstanceKey = "GAE_INSTANCE"

InstanceKey is App Engine Instance Env Key

View Source
const MemoryMBKey = "GAE_MEMORY_MB"

MemoryMBKey is App Engine Memory MB Env Key

View Source
const RuntimeKey = "GAE_RUNTIME"

RuntimeKey is App Engine Runtime Env Key

View Source
const ServiceKey = "GAE_SERVICE"

ServiceKey is App Engine Service Env Key

View Source
const VersionKey = "GAE_VERSION"

VersionKey is App Engine Version Env Key

Variables

This section is empty.

Functions

func DeploymentID

func DeploymentID() (string, error)

DeploymentID is return deployment id The ID of the current deployment. https://cloud.google.com/appengine/docs/standard/go/runtime#environment_variables

func Env

func Env() (string, error)

Env is return env The App Engine environment. Set to standard. https://cloud.google.com/appengine/docs/standard/go/runtime#environment_variables

func Instance

func Instance() (string, error)

Instance is return version id The ID of the instance on which your service is currently running. https://cloud.google.com/appengine/docs/standard/go/runtime#environment_variables

func MemoryMB

func MemoryMB() (string, error)

MemoryMB is return MemoryMB The amount of memory available to the application process, in MB. https://cloud.google.com/appengine/docs/standard/go/runtime#environment_variables

func OnGAE

func OnGAE() bool

OnGAE is GAE上で動いているかどうかを返す GAE用の環境変数があるかどうかを見てるだけなので、偽装可能

func OnGAEReal

func OnGAEReal() bool

OnGAEReal is AppがGAEで動いてるかどうか 環境変数およびOnGCP()も見てるので、本当にGAEで動いてるか

func Runtime

func Runtime() (string, error)

Runtime is return runtime The runtime specified in your app.yaml file. https://cloud.google.com/appengine/docs/standard/go/runtime#environment_variables

func Service

func Service() (string, error)

Service is return service id The service name specified in your app.yaml file. If no service name is specified, it is set to default. https://cloud.google.com/appengine/docs/standard/go/runtime#environment_variables

func Version

func Version() (string, error)

Version is return version id The current version label of your service. https://cloud.google.com/appengine/docs/standard/go/runtime#environment_variables

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL