升级Cloud Endpoint插件后,无法配置App Engine本地IPv4访问地址求助
I totally get the frustration when a familiar configuration stops working after a plugin upgrade—let's get this sorted out for you.
The old appengine { httpAddress = "0.0.0.0" ... } block was deprecated when the Cloud Endpoints plugin was updated, but there are two reliable workarounds to restore IPv4 access:
Option 1: Pass Parameters via Command Line
When you run your App Engine dev server, add these system properties directly to the Gradle command:
./gradlew appengineRun -Dcom.google.appengine.devappserver.Address=0.0.0.0 -Dcom.google.appengine.devappserver.Port=8888
This forces the dev server to bind to all IPv4 interfaces (0.0.0.0) and use your desired port, just like your old configuration did.
Option 2: Configure in build.gradle (Permanent Setup)
If you don't want to type the parameters every time, add this configuration to your build.gradle file to set the properties automatically for the appengineRun task:
tasks.named('appengineRun') { jvmArgs += [ '-Dcom.google.appengine.devappserver.Address=0.0.0.0', '-Dcom.google.appengine.devappserver.Port=8888' ] }
Save the file, then run ./gradlew appengineRun as usual—your server will now default to using the IPv4 address and port you specified.
Both methods work because the Cloud Endpoints plugin now relies on these system properties to configure the dev server's network settings, replacing the old direct configuration block.
内容的提问来源于stack exchange,提问作者Ajeet

