Issue
I am trying to build and deploy apprtc application on my virtual machine(ubuntu 16.04). I have successfully deployed collider server. But I got an error when trying to start apprtc application using google app engine.
Steps followed
run apprtc application using following command:
DIRECTORY_PATH/appengine-java-sdk-1.9.62/bin/dev_appserver.sh out/app_engine/.
Got error like this
Executing [/usr/lib/jvm/java-8-oracle/jre/bin/java, -javaagent:/home/jishnu/manaf/appengine-java-sdk-1.9.62/lib/agent/appengine-agent.jar, -classpath, /home/jishnu/manaf/appengine-java-sdk-1.9.62/lib/appengine-tools-api.jar, com.google.appengine.tools.development.DevAppServerMain, --property=kickstart.user.dir=/home/jishnu/manaf/apprtc, /home/jishnu/manaf/apprtc/out/app_engine/.]
Feb 08, 2018 5:00:03 PM java.util.prefs.FileSystemPreferences$1 run
INFO: Created user preferences directory.
Feb 08, 2018 5:00:06 PM com.google.apphosting.utils.config.AppEngineWebXmlReader readAppEngineWebXml
SEVERE: Received exception processing /home/jishnu/manaf/apprtc/out/app_engine/WEB-INF/appengine-web.xml
com.google.apphosting.utils.config.AppEngineConfigException: Could not locate /home/jishnu/manaf/apprtc/out/app_engine/WEB-INF/appengine-web.xml
at com.google.apphosting.utils.config.AppEngineWebXmlReader.getInputStream(AppEngineWebXmlReader.java:141)
at com.google.apphosting.utils.config.AppEngineWebXmlReader.readAppEngineWebXml(AppEngineWebXmlReader.java:75)
at com.google.apphosting.utils.config.EarHelper.readWebModule(EarHelper.java:178)
at com.google.appengine.tools.development.ApplicationConfigurationManager$WarModuleConfigurationHandle.readConfiguration(ApplicationConfigurationManager.java:417)
at com.google.appengine.tools.development.ApplicationConfigurationManager.<init>(ApplicationConfigurationManager.java:158)
at com.google.appengine.tools.development.ApplicationConfigurationManager.newWarConfigurationManager(ApplicationConfigurationManager.java:100)
at com.google.appengine.tools.development.ApplicationConfigurationManager.newWarConfigurationManager(ApplicationConfigurationManager.java:86)
at com.google.appengine.tools.development.DevAppServerImpl.<init>(DevAppServerImpl.java:142)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at com.google.appengine.tools.development.DevAppServerFactory.doCreateDevAppServer(DevAppServerFactory.java:338)
at com.google.appengine.tools.development.DevAppServerFactory.access$000(DevAppServerFactory.java:31)
at com.google.appengine.tools.development.DevAppServerFactory$1.run(DevAppServerFactory.java:285)
at com.google.appengine.tools.development.DevAppServerFactory$1.run(DevAppServerFactory.java:282)
at java.security.AccessController.doPrivileged(Native Method)
at com.google.appengine.tools.development.DevAppServerFactory.createDevAppServer(DevAppServerFactory.java:281)
at com.google.appengine.tools.development.DevAppServerMain$StartAction.apply(DevAppServerMain.java:348)
at com.google.appengine.tools.util.Parser$ParseResult.applyArgs(Parser.java:45)
at com.google.appengine.tools.development.DevAppServerMain.run(DevAppServerMain.java:223)
at com.google.appengine.tools.development.DevAppServerMain.main(DevAppServerMain.java:214)
Caused by: java.io.FileNotFoundException: /home/jishnu/manaf/apprtc/out/app_engine/WEB-INF/appengine-web.xml (No such file or directory)
at java.io.FileInputStream.open0(Native Method)
at java.io.FileInputStream.open(FileInputStream.java:195)
at java.io.FileInputStream.<init>(FileInputStream.java:138)
at java.io.FileInputStream.<init>(FileInputStream.java:93)
at com.google.apphosting.utils.config.AppEngineWebXmlReader.getInputStream(AppEngineWebXmlReader.java:137)
... 21 more
com.google.apphosting.utils.config.AppEngineConfigException: Invalid configuration
at com.google.appengine.tools.development.DevAppServerImpl.reportDeferredConfigurationException(DevAppServerImpl.java:435)
at com.google.appengine.tools.development.DevAppServerImpl.doStart(DevAppServerImpl.java:232)
at com.google.appengine.tools.development.DevAppServerImpl.access$000(DevAppServerImpl.java:47)
at com.google.appengine.tools.development.DevAppServerImpl$1.run(DevAppServerImpl.java:219)
at com.google.appengine.tools.development.DevAppServerImpl$1.run(DevAppServerImpl.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at com.google.appengine.tools.development.DevAppServerImpl.start(DevAppServerImpl.java:217)
at com.google.appengine.tools.development.DevAppServerMain$StartAction.apply(DevAppServerMain.java:368)
at com.google.appengine.tools.util.Parser$ParseResult.applyArgs(Parser.java:45)
at com.google.appengine.tools.development.DevAppServerMain.run(DevAppServerMain.java:223)
at com.google.appengine.tools.development.DevAppServerMain.main(DevAppServerMain.java:214)
Caused by: com.google.apphosting.utils.config.AppEngineConfigException: Invalid appengine-web.xml(/home/jishnu/manaf/apprtc/out/app_engine/WEB-INF/appengine-web.xml) - Could not locate /home/jishnu/manaf/apprtc/out/app_engine/WEB-INF/appengine-web.xml
at com.google.apphosting.utils.config.EarHelper.readWebModule(EarHelper.java:180)
at com.google.appengine.tools.development.ApplicationConfigurationManager$WarModuleConfigurationHandle.readConfiguration(ApplicationConfigurationManager.java:417)
at com.google.appengine.tools.development.ApplicationConfigurationManager.<init>(ApplicationConfigurationManager.java:158)
at com.google.appengine.tools.development.ApplicationConfigurationManager.newWarConfigurationManager(ApplicationConfigurationManager.java:100)
at com.google.appengine.tools.development.ApplicationConfigurationManager.newWarConfigurationManager(ApplicationConfigurationManager.java:86)
at com.google.appengine.tools.development.DevAppServerImpl.<init>(DevAppServerImpl.java:142)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at com.google.appengine.tools.development.DevAppServerFactory.doCreateDevAppServer(DevAppServerFactory.java:338)
at com.google.appengine.tools.development.DevAppServerFactory.access$000(DevAppServerFactory.java:31)
at com.google.appengine.tools.development.DevAppServerFactory$1.run(DevAppServerFactory.java:285)
at com.google.appengine.tools.development.DevAppServerFactory$1.run(DevAppServerFactory.java:282)
at java.security.AccessController.doPrivileged(Native Method)
at com.google.appengine.tools.development.DevAppServerFactory.createDevAppServer(DevAppServerFactory.java:281)
at com.google.appengine.tools.development.DevAppServerMain$StartAction.apply(DevAppServerMain.java:348)
... 3 more
Expected results
As per documentation, after this step, we should successfully access the apprtc application using http://localhost:443 url.
What is the actual issue with steps I followed?
com.google.apphosting.utils.config.AppEngineConfigException: Could not locate /home/jishnu/manaf/apprtc/out/app_engine/WEB-INF/appengine-web.xml
Well, from apprtc/src/app_engine/app.yaml it looks like the app is a python app, not a java one. There is no WEB-INF/appengine-web.xml
for a python app.
So you need to:
run the python development server, depending which SDK you use :
<gcloud_sdk>/bin/dev_appserver.py out/app_engine/.
or
<gae_python_sdk>/dev_appserver.py out/app_engine/.
This is more or less specified in the apprtc README.md
at the source code page you referenced:
Running AppRTC locally requires Google App Engine SDK for Python,
...
Start the AppRTC dev server from the out/app_engine directory by running the Google App Engine SDK dev server,
<path to sdk>/dev_appserver.py ./out/app_engine