Use of the new 'roothttp' option
authorJosé Bollo <jose.bollo@iot.bzh>
Wed, 31 Aug 2016 12:44:04 +0000 (14:44 +0200)
committerJosé Bollo <jose.bollo@iot.bzh>
Wed, 31 Aug 2016 12:44:04 +0000 (14:44 +0200)
The new option 'roothttp' set the root directory that the
HTTP part of the binder serves. Its default value is ".".

Using this option, the content accessible through HTTP can be
a subdirectory of the root and in the same time, the application
data are available in the root directory.

Change-Id: I30d5f78eb2fe500b840fe0f4869d3e54be69c3cf
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
conf/afm-launch.conf.in

index 60d204b..a70fd60 100644 (file)
@@ -29,10 +29,10 @@ application/vnd.agl.url
        /usr/bin/web-runtime %c
 
 application/vnd.agl.service
-       /usr/bin/afb-daemon --ldpaths=@CMAKE_INSTALL_FULL_LIBDIR@/afb:%r/%c --mode=local --readyfd=%R --alias=/icons:%I --port=%P --rootdir=%r/htdocs --token=%S --sessiondir=%D/.afb-daemon
+       /usr/bin/afb-daemon --ldpaths=@CMAKE_INSTALL_FULL_LIBDIR@/afb:%r/%c --mode=local --readyfd=%R --alias=/icons:%I --port=%P --rootdir=%r --roothttp=htdocs --token=%S --sessiondir=%D/.afb-daemon
 
 application/vnd.agl.native
-       /usr/bin/afb-daemon --ldpaths=@CMAKE_INSTALL_FULL_LIBDIR@/afb:%r/lib --mode=local --readyfd=%R --alias=/icons:%I --port=%P --rootdir=%r/htdocs --token=%S --sessiondir=%D/.afb-daemon
+       /usr/bin/afb-daemon --ldpaths=@CMAKE_INSTALL_FULL_LIBDIR@/afb:%r/lib --mode=local --readyfd=%R --alias=/icons:%I --port=%P --rootdir=%r --roothttp=htdocs --token=%S --sessiondir=%D/.afb-daemon
        %r/%c %P %S
 
 text/vnd.qt.qml
@@ -40,11 +40,11 @@ application/vnd.agl.qml
        /usr/bin/qt5/qmlscene -fullscreen -I %r -I %r/imports %r/%c
 
 application/vnd.agl.qml.hybrid
-       /usr/bin/afb-daemon --ldpaths=@CMAKE_INSTALL_FULL_LIBDIR@/afb:%r/lib --mode=local --readyfd=%R --alias=/icons:%I --port=%P --rootdir=%r/htdocs --token=%S --sessiondir=%D/.afb-daemon
+       /usr/bin/afb-daemon --ldpaths=@CMAKE_INSTALL_FULL_LIBDIR@/afb:%r/lib --mode=local --readyfd=%R --alias=/icons:%I --port=%P --rootdir=%r --roothttp=htdocs --token=%S --sessiondir=%D/.afb-daemon
        /usr/bin/qt5/qmlscene %P %S -fullscreen -I %r -I %r/imports %r/%c
 
 application/vnd.agl.html.hybrid
-       /usr/bin/afb-daemon --ldpaths=@CMAKE_INSTALL_FULL_LIBDIR@/afb:%r/lib --mode=local --readyfd=%R --alias=/icons:%I --port=%P --rootdir=%r/htdocs --token=%S --sessiondir=%D/.afb-daemon
+       /usr/bin/afb-daemon --ldpaths=@CMAKE_INSTALL_FULL_LIBDIR@/afb:%r/lib --mode=local --readyfd=%R --alias=/icons:%I --port=%P --rootdir=%r --roothttp=htdocs --token=%S --sessiondir=%D/.afb-daemon
        /usr/bin/web-runtime http://localhost:%P/%c?token=%S
 
 #-----------------