diff options
author | José Bollo <jose.bollo@iot.bzh> | 2019-12-03 15:02:57 +0100 |
---|---|---|
committer | José Bollo <jose.bollo@iot.bzh> | 2019-12-03 18:37:21 +0100 |
commit | 6008a3ec4d1c0ed5df338b7c5f0775585ab51cfb (patch) | |
tree | 1ac16f60d411822d149a77379faec0bdd8851d0d /conf | |
parent | 50ab763bc31cb9e32bcb7e08e1f2be502fc50a5f (diff) |
Enforce numeric application IDs
This change allows to index applications numerically.
This can be used for various purposes. One of it is
to compute the HTTP port.
Bug-AGL: SPEC-2968
Change-Id: I74531781f3a39d5d4b09eeb907f57f36822e38f0
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
Diffstat (limited to 'conf')
-rw-r--r-- | conf/unit/macros.inc | 2 | ||||
-rw-r--r-- | conf/unit/service.inc | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/conf/unit/macros.inc b/conf/unit/macros.inc index ca72b95..f21dee5 100644 --- a/conf/unit/macros.inc +++ b/conf/unit/macros.inc @@ -44,6 +44,7 @@ define( `IF_NOT_VALUE', `MUSTACH_IF_NOT(value=$1)') -- use TARGET={{:id}}--{{:ver}}--{{:#target}} -- instead of TARGET={{idaver}}{{^#target=main}}@{{:#target}}{{/#target=main}} -------------------------------------------------------------------------------- +define( `AFID', `{{:#metatarget.afid}}') define( `SMACKLABEL', `User::App::{{:id}}') define( `TARGET', `{{idaver}}{{^#target=main}}@{{:#target}}{{/#target=main}}') define( `NEWTARGET', `{{:id}}--{{:ver}}--{{:#target}}') @@ -74,6 +75,7 @@ define( `PLATFORM_API_PATH_LINK', `PLATFORM_API_PATH/link') define( `USER_API_PATH', `USER_RUN_DIR/apis') define( `USER_API_PATH_WS', `USER_API_PATH/ws') define( `USER_API_PATH_LINK', `USER_API_PATH/link') + -------------------------------------------------------------------------------- -- AGL_DEVEL SPECIFIC PARTS -------------------------------------------------------------------------------- diff --git a/conf/unit/service.inc b/conf/unit/service.inc index 64e6e5f..0036cae 100644 --- a/conf/unit/service.inc +++ b/conf/unit/service.inc @@ -28,7 +28,7 @@ X-AFM-height={{height}} {{#icon}} X-AFM-icon={{:#metadata.install-dir}}/{{:src}} {{/icon}} -X-AFM--ID={{:id}} +X-AFM--ID=AFID X-AFM--target-name={{:#target}} X-AFM--content={{content.src}} X-AFM--type={{content.type}} |