HEX
Server: Apache/2.4.65 (Ubuntu)
System: Linux ielts-store-v2 6.8.0-1036-gcp #38~22.04.1-Ubuntu SMP Thu Aug 14 01:19:18 UTC 2025 x86_64
User: root (0)
PHP: 7.2.34-54+ubuntu20.04.1+deb.sury.org+1
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,
Upload Files
File: //snap/google-cloud-cli/396/help/man/man1/gcloud_app_deploy.1
.TH "GCLOUD_APP_DEPLOY" 1



.SH "NAME"
.HP
gcloud app deploy \- deploy the local code and/or configuration of your app to App Engine



.SH "SYNOPSIS"
.HP
\f5gcloud app deploy\fR [\fIDEPLOYABLES\fR\ ...] [\fB\-\-appyaml\fR=\fIAPPYAML\fR] [\fB\-\-bucket\fR=\fIBUCKET\fR] [\fB\-\-no\-cache\fR] [\fB\-\-ignore\-file\fR=\fIIGNORE_FILE\fR] [\fB\-\-image\-url\fR=\fIIMAGE_URL\fR] [\fB\-\-no\-promote\fR] [\fB\-\-service\-account\fR=\fISERVICE_ACCOUNT\fR] [\fB\-\-no\-stop\-previous\-version\fR] [\fB\-\-version\fR=\fIVERSION\fR,\ \fB\-v\fR\ \fIVERSION\fR] [\fIGCLOUD_WIDE_FLAG\ ...\fR]



.SH "DESCRIPTION"

This command is used to deploy both code and configuration to the App Engine
server. As an input it takes one or more DEPLOYABLES that should be uploaded. A
DEPLOYABLE can be a service's .yaml file or a configuration's .yaml file (for
more information about configuration files specific to your App Engine
environment, refer to
https://cloud.google.com/appengine/docs/standard/configuration\-files or
https://cloud.google.com/appengine/docs/flexible/configuration\-files). Note,
for Java 8 Standard apps or Java 11/17/21 Standard apps using bundled services,
you must add the path to the appengine\-web.xml file inside the WEB\-INF
directory. gcloud app deploy skips files specified in the .gcloudignore file
(see gcloud topic gcloudignore for more information). For Java 11 Standard, you
can either use the yaml file, a Maven pom.xml, or a Gradle build.gradle.
Alternatively, if the application is a single self\-contained jar, you can give
the path to the jar and a simple service configuration will be generated. You
can deploy Java 11 Maven source projects by specifying the location of your
project's pom.xml file, and it will be built and deployed using App Engine
Buildpacks.



.SH "EXAMPLES"

To deploy a single service, run:

.RS 2m
$ gcloud app deploy ~/my_app/app.yaml
.RE

To deploy an App Engine Standard Java8 service or a Java11 service using bundled
services, run:

.RS 2m
$ gcloud app deploy ~/my_app/WEB\-INF/appengine\-web.xml
.RE

To deploy an App Engine Standard Java11 single jar, run:

.RS 2m
$ gcloud app deploy ~/my_app/my_jar.jar
.RE

To deploy an App Engine Standard Java11 Maven source project, run:

.RS 2m
$ gcloud app deploy ~/my_app/pom.xml
.RE

To deploy an App Engine Standard Java11 Gradle source project, run:

.RS 2m
$ gcloud app deploy ~/my_app/build.gradle
.RE

By default, the service is deployed to the current project configured via:

.RS 2m
$ gcloud config set core/project PROJECT
.RE

To override this value for a single deployment, use the \f5\fI\-\-project\fR\fR
flag:

.RS 2m
$ gcloud app deploy ~/my_app/app.yaml \-\-project=PROJECT
.RE

To deploy multiple services, run:

.RS 2m
$ gcloud app deploy ~/my_app/app.yaml ~/my_app/another_service.yaml
.RE

To change the default \-\-promote behavior for your current environment, run:

.RS 2m
$ gcloud config set app/promote_by_default false
.RE

To deploy a service that will run as a service account, run:

.RS 2m
$ gcloud app deploy ~/my_app/app.yaml \e
    \-\-service\-account=SERVICE_ACCOUNT
.RE



.SH "POSITIONAL ARGUMENTS"

.RS 2m
.TP 2m
[\fIDEPLOYABLES\fR ...]

The yaml files for the services or configurations you want to deploy. If not
given, defaults to \f5app.yaml\fR in the current directory. If that is not
found, attempts to automatically generate necessary configuration files (such as
app.yaml) in the current directory.


.RE
.sp

.SH "FLAGS"

.RS 2m
.TP 2m
\fB\-\-appyaml\fR=\fIAPPYAML\fR

Deploy with a specific app.yaml that will replace the one defined in the
DEPLOYABLE.

.TP 2m
\fB\-\-bucket\fR=\fIBUCKET\fR

The Google Cloud Storage bucket used to stage files associated with the
deployment. If this argument is not specified, the application's default code
bucket is used.

.TP 2m
\fB\-\-cache\fR

Enable caching mechanisms involved in the deployment process, particularly in
the build step. Enabled by default, use \fB\-\-no\-cache\fR to disable.

.TP 2m
\fB\-\-ignore\-file\fR=\fIIGNORE_FILE\fR

Override the .gcloudignore file and use the specified file instead.

.TP 2m
\fB\-\-image\-url\fR=\fIIMAGE_URL\fR

(App Engine flexible environment only.) Deploy with a specific Docker image.
Docker url must be from one of the valid Artifact Registry hostnames.

.TP 2m
\fB\-\-promote\fR

Promote the deployed version to receive all traffic. Overrides the default
\fBapp/promote_by_default\fR property value for this command invocation. Use
\fB\-\-no\-promote\fR to disable.

.TP 2m
\fB\-\-service\-account\fR=\fISERVICE_ACCOUNT\fR

The service account that this deployed version will run as. If this argument is
not specified, the App Engine default service account will be used for your
current deployed version.

.TP 2m
\fB\-\-stop\-previous\-version\fR

Stop the previously running version when deploying a new version that receives
all traffic.

Note that if the version is running on an instance of an auto\-scaled service in
the App Engine Standard environment, using \f5\-\-stop\-previous\-version\fR
will not work and the previous version will continue to run because auto\-scaled
service instances are always running.

Overrides the default \fBapp/stop_previous_version\fR property value for this
command invocation. Use \fB\-\-no\-stop\-previous\-version\fR to disable.

.TP 2m
\fB\-\-version\fR=\fIVERSION\fR, \fB\-v\fR \fIVERSION\fR

The version of the app that will be created or replaced by this deployment. If
you do not specify a version, one will be generated for you.


.RE
.sp

.SH "GCLOUD WIDE FLAGS"

These flags are available to all commands: \-\-access\-token\-file, \-\-account,
\-\-billing\-project, \-\-configuration, \-\-flags\-file, \-\-flatten,
\-\-format, \-\-help, \-\-impersonate\-service\-account, \-\-log\-http,
\-\-project, \-\-quiet, \-\-trace\-token, \-\-user\-output\-enabled,
\-\-verbosity.

Run \fB$ gcloud help\fR for details.



.SH "NOTES"

This variant is also available:

.RS 2m
$ gcloud beta app deploy
.RE