Skip to content

Commit a4111dd

Browse files
committed
Changed App Identity sample to use Managed VMs.
1 parent 580b669 commit a4111dd

File tree

3 files changed

+12
-8
lines changed

3 files changed

+12
-8
lines changed

appengine/appidentity/README.md

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,29 @@
22
This sample demonstrates how to use the App Identity APIs on Google App Engine
33

44
## Running locally
5-
$ mvn appengine:devserver
5+
This example uses the
6+
[Maven gcloud plugin](https://cloud.google.com/appengine/docs/java/managed-vms/maven).
7+
To run this sample locally:
8+
9+
$ mvn gcloud:run
610

711
## Deploying
812
In the following command, replace YOUR-PROJECT-ID with your
913
[Google Cloud Project ID](https://developers.google.com/console/help/new/#projectnumber)
1014
and YOUR-VERSION with a suitable version identifier.
1115

12-
$ mvn appengine:update -Dappengine.appId=YOUR-PROJECT-ID -Dappengine.version=YOUR-VERSION
16+
$ mvn gcloud:deploy -Dversion=YOUR-VERSION -Dgcloud_project=YOUR-PROJECT-ID
1317

1418
## Setup
1519
To save your project settings so that you don't need to enter the
16-
`-Dappengine.appId=YOUR-CLOUD-PROJECT-ID` or
17-
`-Dappengine.version=YOUR-VERSION-NAME` parameters, you can make the following
18-
changes:
20+
`-Dgcloud_project=YOUR-CLOUD-PROJECT-ID` or `-Dversion=YOUR-VERSION-NAME`
21+
parameters, you can make the following changes:
1922

2023
1. Update the <application> tag in src/main/webapp/WEB-INF/appengine-web.xml with your project name
2124
1. Update the <version> tag in src/main/webapp/WEB-INF/appengine-web.xml with your version name
2225

2326
You will now be able to run
2427

25-
$ mvn appengine:update
28+
$ mvn gcloud:deploy
2629

2730
without the need for any additional paramters.

appengine/appidentity/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,8 @@ Copyright 2015 Google Inc. All Rights Reserved.
9494
</plugin>
9595
<plugin>
9696
<groupId>com.google.appengine</groupId>
97-
<artifactId>appengine-maven-plugin</artifactId>
98-
<version>${appengine.target.version}</version>
97+
<artifactId>gcloud-maven-plugin</artifactId>
98+
<version>2.0.9.90.v20151210</version>
9999
</plugin>
100100
</plugins>
101101
</build>

appengine/appidentity/src/main/webapp/WEB-INF/appengine-web.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
<application>YOUR-PROJECT-ID</application>
44
<version>YOUR-VERSION-ID</version>
55
<threadsafe>true</threadsafe>
6+
<vm>true</vm>
67
</appengine-web-app>

0 commit comments

Comments
 (0)