58 lines
3.4 KiB
Markdown
58 lines
3.4 KiB
Markdown
# Hlæja Device API
|
|
|
|
Classes and endpoints, to shape and to steer, Devices and sensors, their purpose made clear. Each message exchanged, each packet that waits, Travels through layers, as data translates. API pathways, structured and strong, Link devices to services, where data belongs. Bound by one purpose, data flows onward, Answering each call, steadfast and forward.
|
|
|
|
## Properties for deployment
|
|
|
|
| name | required | info |
|
|
|----------------------------------------------|:--------:|----------------------------------------------|
|
|
| spring.profiles.active | ✓ | Spring Boot environment |
|
|
| server.port | ✓ | HTTP port |
|
|
| server.ssl.enabled | ✓ | HTTP Enable SSL |
|
|
| server.ssl.key-store | ✓ | HTTP Keystore |
|
|
| server.ssl.key-store-type | ✓ | HTTP Cert Type |
|
|
| server.ssl.key-store-password | ✗ | HTTP Cert Pass |
|
|
| account-registry.url | ✓ | Account Register URL |
|
|
| device-registry.url | ✓ | Device Register URL |
|
|
| management.influx.metrics.export.api-version | | InfluxDB API version |
|
|
| management.influx.metrics.export.enabled | | Enable/Disable exporting metrics to InfluxDB |
|
|
| management.influx.metrics.export.bucket | ✓ | InfluxDB bucket name |
|
|
| management.influx.metrics.export.org | ✓ | InfluxDB organization |
|
|
| management.influx.metrics.export.token | ✗ | InfluxDB token |
|
|
| management.influx.metrics.export.uri | ✓ | InfluxDB URL |
|
|
| management.metrics.tags.application | ✓ | Application instance tag for metrics |
|
|
|
|
*Required: ✓ can be stored as text, and ✗ need to be stored as secret.*
|
|
|
|
## Releasing Service
|
|
|
|
Run `release.sh` script from `master` branch.
|
|
|
|
## Development Configuration
|
|
|
|
### Developer Keystore
|
|
|
|
We use a keystore to enable HTTPS for our API. To set up your developer environment for local development, please refer to [generate keystore](https://github.com/swordsteel/hlaeja-development/blob/master/doc/keystore.md) documentation. When generating and exporting the certificate for local development, please store it in the `./cert/keystore.p12` folder at the project root.
|
|
|
|
### Global Settings
|
|
|
|
This services rely on a set of global settings to configure development environments. These settings, managed through Gradle properties or environment variables.
|
|
|
|
*Note: For more information on global properties, please refer to our [global settings](https://github.com/swordsteel/hlaeja-development/blob/master/doc/global_settings.md) documentation.*
|
|
|
|
#### Gradle Properties
|
|
|
|
```properties
|
|
repository.user=your_user
|
|
repository.token=your_token_value
|
|
influxdb.token=your_token_value
|
|
```
|
|
|
|
#### Environment Variables
|
|
|
|
```properties
|
|
REPOSITORY_USER=your_user
|
|
REPOSITORY_TOKEN=your_token_value
|
|
INFLUXDB_TOKEN=your_token_value
|
|
```
|