Home monitoring API part of the Nidus project, see the Nidus API Specification
- Manage devices, zones, capabilities
- Pair device
- Create alerts and notifications
- Security
- Key
- Tests
This application is part of a Docker stack and rely on a MongoDB database service. see:
Nidus project to launch the
complete stack or only the database
service.
If the database service is up and running, create an .env file and fill it
accordingly with the database
service configuration.
ENV=dev
PAIRING_KEY=9fca54477c8ad4e70dc5e1084f884aad
JWT_SECRET=d7a481461577ba4c3c4c6946cca7204b
JWT_EXPIRE=90
BCRYPT_HASH=7f91317e30a02bc7b87205e95b842df2
DATABASE_URI=mongodb://nidus:nidus@localhost:27017/nidus
Run the application:
go run cmd/main.go
Go to http://localhost:3333
To implement
Build the image, see: Dockerfile.
docker build . -t alexandrelamberty/nidus-api:latest
Run the image, we specify the ports mapping, environment variables file and network to join.
docker run -p 3333:3333 --network=nidus_default --env-file .env --name nidus-api -d alexandrelamberty/nidus-api:latest