summaryrefslogtreecommitdiffstats
path: root/conf/unit/generate-unit-conf/binder.inc
diff options
context:
space:
mode:
authorJosé Bollo <jose.bollo@iot.bzh>2019-05-15 20:49:14 +0200
committerJosé Bollo <jose.bollo@iot.bzh>2019-06-04 09:52:31 +0200
commit5b801a3e7b0465f88b785a155dd430ba09c56568 (patch)
tree82e06c5e13c7a4652170e17665f74496539a7022 /conf/unit/generate-unit-conf/binder.inc
parenta5cf62686366f4a69becf62aa4d953e034c9bee4 (diff)
afm-unit.conf: Refactor its generation
The process of generating the file /etc/afm-unit.conf had be reworked to be more straight forward. Before that commit, a manual operation (a "make") had to be done before committing the repository. This was not efficient, error prone and kept temporary files in conf. That commit changes it by calling m4 through cmake. Bug-AGL: SPEC-2436 Change-Id: Ia32a810286471dde8a01387d157e33277d67411d Signed-off-by: Jose Bollo <jose.bollo@iot.bzh>
Diffstat (limited to 'conf/unit/generate-unit-conf/binder.inc')
-rw-r--r--conf/unit/generate-unit-conf/binder.inc51
1 files changed, 0 insertions, 51 deletions
diff --git a/conf/unit/generate-unit-conf/binder.inc b/conf/unit/generate-unit-conf/binder.inc
deleted file mode 100644
index 30c25d5..0000000
--- a/conf/unit/generate-unit-conf/binder.inc
+++ /dev/null
@@ -1,51 +0,0 @@
-dnl vim: set filetype=sysctl.conf.m4 syntax=sysctl.conf.m4:
-
-IF_AGL_DEVEL
-X-AFM-http-port={{:#metatarget.http-port}}
-ELSE
-IF_NOT_CONTENT(application/vnd.agl.service)
-X-AFM--http-port={{:#metatarget.http-port}}
-ENDIF
-ENDIF
-
-Type=notify
-ExecStart=/usr/bin/afb-daemon \
- --name afbd-TARGET \
- --rootdir={{:#metadata.install-dir}} \
- --workdir=APP_DATA_DIR/{{id}} \
-IF_AGL_DEVEL \
- --verbose \
- --verbose \
- --monitoring \
- --port={{:#metatarget.http-port}} \
- --token=HELLO \
- --roothttp=ON_CONTENT(application/vnd.agl.service, ., ON_PERM(:public:no-htdocs, ., htdocs)) \
-ELSE \
- IF_CONTENT(application/vnd.agl.service) \
- --no-httpd \
- ELSE \
- --port={{:#metatarget.http-port}} \
- --random-token \
- --roothttp=ON_PERM(:public:no-htdocs, ., htdocs) \
- ENDIF \
-ENDIF \
- ON_PERM(:public:applications:read, --alias=/icons:{{:#metadata.icons-dir}}) \
- {{#required-api}} \
- ON_VALUE(auto|ws, --ws-client=unix:API_PATH_WS/{{name}}) \
- ON_VALUE(dbus, --dbus-client={{name}}) \
- ON_VALUE(cloud, --cloud-client={{name}}) \
- ON_VALUE(local, --binding={{:#metadata.install-dir}}/{{name}}) \
- ON_VALUE(tcp, --ws-client=tcp:{{name}}) \
- {{/required-api}} \
- {{#required-binding}} \
- ON_VALUE(local, --binding={{:#metadata.install-dir}}/{{name}}) \
- ON_VALUE(extern, --binding=API_PATH_LINK/{{name}}) \
- {{/required-binding}} \
- {{#provided-api}} \
- ON_VALUE(auto|ws, --ws-server=sd:{{name}}) \
- ON_VALUE(dbus, --dbus-server={{name}}) \
- ON_VALUE(tcp, --ws-server=tcp:{{name}}) \
- {{/provided-api}} \
- ON_CONTENT(text/html, --exec /usr/bin/web-runtime http://localhost:@p/{{content.src}}?token=@t) \
- ON_CONTENT(application/vnd.agl.native, --exec {{:#metadata.install-dir}}/{{content.src}} @p @t)
-