FOG-979: PID File for foglamp core (#551)
FOG-979: PID File for foglamp core (#551)

* FOG-979: PID File for foglamp core

PID File for foglamp core.

Pid file is created with JSON data in it at startup, just after REST API details are knwon.

It's removed when FogLAMP core ends.

* FOGL-979: better error handling and _remove_pid() added

FOGL-979: better error handling and _remove_pid() added

* FOGL-979: fixed comment style

FOGL-979: fixed comment style

* FOGL-979: changed REST_info to adminAPI

FOGL-979: changed REST_info to adminAPI

Added 'addresses' array instead of address.

In a future commit "addresses" will contain all the listening IPs

{
  "processID": 27114,
  "adminAPI": {
    "protocol": "HTTP",
    "addresses": [
      "0.0.0.0"
    ],
    "port": 8081
  }
}

foglamp/FogLAMP,foglamp/FogLAMP,foglamp/FogLAMP,foglamp/FogLAMP