Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

fog-controller

0.1.6 • Public • Published

Fog Controller Setup

1. Install fog-controller

   npm install –g fog-controller

2. Create user

   fog-controller user -add <email> <firstName> <lastName>

3. Start fog-controller

   fog-controller start

4. Open your browser and hit following endpoints to setup IOFog, provision key and fog access token.

  • Create Fog

   http://localhost:3000/api/v2/instance/create/type/:type?userId=:userAccessToken

   where ':type' is FogType which can be 1 for Standard Linux (x86) OR 2 for ARM Linux

   and ':userAccessToken' is obtained by creating user

  • Fog provisioning

   http://localhost:3000/api/v2/authoring/fabric/provisionkey/instanceid/:instanceId

   where :instanceId' is obtained by creating fog. This provision key can be provided to ioFog for provisioning.

  • Create fog access token

   http://localhost:3000/api/v2/instance/provision/key/:provisionKey/fabrictype/:fabricType

   where ':provisionKey' is obtained by provisioning fog

    and ':fabricType' is a FogType

Fog Controller Configuration

1. To start fog-controller

    fog-controller start

2. To set configurations

    fog-controller set <key> <value>

Note: Configuration keys can be one of following

  • PORT
  • SSL_KEY
  • SSL_CERT
  • INTERMEDIATE_CERT

To setup HTTPS for fog controller, do following steps:

    fog-controller set PORT 443
    fog-controller set SSL_KEY '/home/certificates/key.pem'
    fog-controller set INTERMEDIATE_CERT '/home/certificates/gs_intermediate_ca.crt'
    fog-controller set SSL_CERT '/home/certificates/certificate.pem'

3. To list the users

    fog-controller user
    OR
    fog-controller user -list

4. To add a user

    fog-controller user -add <email> <firstName> <lastName>

5. To remove a user

    fog-controller user -remove <email>

6. To reset password

    fog-controller user -generateToken <email>

Keywords

Install

npm i [email protected]

Version

0.1.6

License

Copyright (C) 2017 iotracks, inc. Eclipse ioFog is provided under the Eclipse Public License (EPL) https://www.eclipse.org/legal/epl-v10.html

Last publish

Collaborators

  • avatar