diff options
author | Romain Forlot <romain.forlot@iot.bzh> | 2017-05-18 17:49:35 +0200 |
---|---|---|
committer | Romain Forlot <romain.forlot@iot.bzh> | 2017-05-18 17:49:35 +0200 |
commit | 162d50a33b8c72d09bd3dc82967c36d559f8278f (patch) | |
tree | 337b11ad4c7a9bfa9de46cde0a84a08411043845 /templates/service/README.md | |
parent | 6993026755563379e964966ee7fc73923a21828d (diff) |
Git repo can be used as submodules
Clean templates files as they are useless for usage in submodules into a project.
Change-Id: I24c71b64ab2b3a958494f3f190c014227a1da576
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'templates/service/README.md')
-rw-r--r-- | templates/service/README.md | 66 |
1 files changed, 0 insertions, 66 deletions
diff --git a/templates/service/README.md b/templates/service/README.md deleted file mode 100644 index 17c9869..0000000 --- a/templates/service/README.md +++ /dev/null @@ -1,66 +0,0 @@ -# Application Framework - Service Template - -## Instructions - -Duplicate directory and adjust names. In particular, replace 'xxxxxx' by a proper service name. - -* adjust CMakeLists.txt (project name and version) -* ajdust config.xml (description, author, license...) -* rename xxxxxx-service-binding.c to something meaningful -* store icon file in icons directory and update the variable PROJECT_ICON in CMakeLists.txt - -## Build - -Run: - -``` -mkdir build -cd build -cmake .. -make -``` - -## Deployment - -Copy the .wgt file on the target through ssh and install it (adjust BOARDIP to your real IP address): - -``` -$ BOARDIP=1.2.3.4 -$ scp xxxxxx-service.wgt root@$BOARDIP:/tmp -$ ssh root@$BOARDIP -# afm-util install /tmp/xxxxxx-service.wgt -# afm-util list -``` - -## Run service manually - -On the target board: - -``` -# afm-util start xxxxxx-server@0.1 -# ps -ef| grep afb-daemon | grep xxx -``` - -## Test using curl - -``` -# PORT=12345 # adjust the port depending in on afb-daemon instance: use ps -ef to check -# curl -v http://localhost:$PORT/api/xxxxxx/ping -* Trying 127.0.0.1... -* Connected to localhost (127.0.0.1) port 5555 (#0) -> GET /api/xxxxxx/ping HTTP/1.1 -> Host: localhost:5555 -> User-Agent: curl/7.44.0 -> Accept: */* -> -< HTTP/1.1 200 OK -< Connection: Keep-Alive -< Content-Length: 184 -< Set-Cookie: x-afb-uuid-5555=30ab9573-cbc8-43f7-b385-0186feebc69a; Path=/api; Max-Age=3600; HttpOnly -< Date: Sun, 10 Jul 2016 00:09:14 GMT -< -* Connection #0 to host localhost left intact -{"response":"Some String","jtype":"afb-reply","request":{"status":"success","info":"Ping Binder Daemon tag=pingSample count=1 query={ }","uuid":"30ab9573-cbc8-43f7-b385-0186feebc69a"}}root@porter:~# -``` - - |