Mainflux.mainflux/dashflux
Dušan Borovčanin 808ac50792 MF-282 - Rename clients to things in Dashflux (#305)
* Rename services, stores, environments and models

Rename services, stores and models to match naming change from `clients` to `things`.

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Replace all occurrences of clients with things

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Update docker-compose and nginx.conf

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Rename `clients service` to `things service`

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Rename function and veriable names

Remove other occurences of `clients` word/prefix/sufix and replace it with `things`.

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Fix error sending id

Id field must not be sent in POST request in order to create a new thing.

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Disable thing type edit

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Export location header

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Update docker config to use port 3000

Update docker-compose.

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Replace id check with bool variable

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>

* Rename dialogs

Fix bug when creating channel with no connected things.

Signed-off-by: Dušan Borovčanin <dusan.borovcanin@mainflux.com>
2018-05-24 15:26:03 +02:00
..
docker MF-282 - Rename clients to things in Dashflux (#305) 2018-05-24 15:26:03 +02:00
e2e MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
src MF-282 - Rename clients to things in Dashflux (#305) 2018-05-24 15:26:03 +02:00
.angular-cli.json MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
.editorconfig MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
.gitignore MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
LICENSE MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
README.md NOISSUE - Automate Dashflux container deployment (#261) 2018-05-10 10:39:48 +02:00
karma.conf.js MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
package-lock.json MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
package.json MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
protractor.conf.js MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
proxy-config.json MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
tsconfig.json MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00
tslint.json MF-244 - Integrate Dashflux (#258) 2018-05-09 12:32:49 +02:00

README.md

Mainflux UI Dashboad

Mainflux UI, dashboard for Mainflux Industrial IoT Messaging and Device Management Server.

N.B. Mainflux UI service is WIP and not suitable for deployment at this moment. You are welcome to contribute and improve it.

Development

Requirements

You'll need the following software installed to get started.

  • Node 6 or higher, we recommend current LTS version, together with NPM 3 or higher.
  • Angular-cli Newest version with Webpack integration
    • Depending on how Node is configured on your machine, you may need to run installation command with sudo
  • Git: Use the installer for your OS.
  • For local Development with Mainflux composition running locally, Chrome extension for Cross origin is required. Because composition is running on different port then our Angular app, we have cross origin.

Configuration

Change into the directory.

cd dashflux

Install the dependencies. If you're running Mac OS or Linux, you may need to run sudo npm install instead, depending on how your machine is configured.

npm install

Set appropriate endpoint URLs in environment.ts (for local development will probably be 0.0.0.0:<port>) or environment.prod.ts for production.

To start the server, run:

ng serve

This will run and assemble our app. Now go to localhost:4200 in your browser to see it in action.

Deployment

Dashflux is distributed as Docker container. We use nginx to serve dashflux from docker container, supporting environments using docker multi-stage builds. Dashflux docker image is available on Dockerhub mainflux/dashflux

If you want to build image locally, you can build image using the development environment:

docker build -f docker/Dockerfile  -t dashflux:dev --build-arg env=dev .

Build image using the production environment:

docker build -t dashflux:prod -f ./docker/Dockerfile .

Note: before running docker build command, please make sure appropriate endpoint URLs in environment.ts or environment.prod.ts are set up.

You can test image running

docker run -p 80:80 dashflux:dev

This will run dashflux in docker container.

Now go to http://localhost in your browser to see it in action.