Run/debug configurations for a Google App Engine project in Intellij IDEA?

690 Views Asked by At

As per title. Right now my workflow is as follows:

To deploy: Open terminal from IDEA, go mvn appengine:deploy.

To run in localhost: Open terminal, go mvn appengine:devserver.

To debug in localhost: thanks to this answer, open terminal, go

mvn appengine:devserver
mvn appengine:devserver_stop
mvn appengine:devserver_start

And then run the remote configuration which is described in that answer.

Question

Can these 3 tasks be simplified by defining three configurations, so to avoid having to open terminal and type commands?

I’d like to have two run configurations to deploy and run in localhost, and one debug configuration to debug locally. Is that possible? How?

Note: I am using the Community Edition of IntelliJ.

For what it’s worth, I have commented in the appropriate lines in pom.xml:

<plugin>
    <groupId>com.google.appengine</groupId>
    <artifactId>appengine-maven-plugin</artifactId>
    <version>${appengine.version}</version>
    <configuration>
        <enableJarClasses>false</enableJarClasses>
        <version>${app.version}</version>
        <!-- Comment in the below snippet to bind to all IPs instead of just localhost -->
        <!-- address>0.0.0.0</address>
        <port>8080</port -->
        <!-- Comment in the below snippet to enable local debugging with a remote debugger
             like those included with Eclipse or IntelliJ -->
        <jvmFlags>
          <jvmFlag>-agentlib:jdwp=transport=dt_socket,address=8000,server=y,suspend=n</jvmFlag>
        </jvmFlags>
    </configuration>
</plugin>
0

There are 0 best solutions below