-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ad4eb2f
commit 2cf13ab
Showing
8 changed files
with
79 additions
and
57 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,7 @@ license = "MIT OR Apache-2.0" | |
name = "omnect-ui" | ||
readme = "README.md" | ||
repository = "[email protected]:omnect/omnect-ui.git" | ||
version = "0.1.0" | ||
version = "0.1.1" | ||
|
||
[dependencies] | ||
actix-files = "0.6" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,12 +5,60 @@ This module implements a web frontend and backend to provide omnect specific fea | |
|
||
## Install omnect-ui | ||
|
||
OMNECT_WAIT_ONLINE_TIMEOUT_IN_SECS | ||
Since omnect-os is designed as generic OS all specific or optional applications must be provided as docker images. There are two options to install omnect-ui on a target: | ||
1. azure iotedge deployment: | ||
- deployement of omnect-ui docker image via omnect-portal to a device in field. The | ||
- device must be online (at least once) in order to receive the deployment | ||
- after a factory reset the omnect-ui must be deployed again what requires a connection to azure again | ||
2. in-factory installation (check [meta-omnect](https://github.com/omnect/meta-omnect) for partition layout): | ||
- inject omnect-ui docker image into factory partition | ||
- omnect-os takes care of installation while first boot and after factory reset | ||
|
||
### iotedge deployement | ||
|
||
In case it is agreed the omnect takes care to provide omnect-ui as application in omnect-portal. Get into contact with [email protected] if interested. | ||
|
||
### Inject into omnect-os image | ||
|
||
If omnect-ui must be part of the omnect-os image, several configuration files must injected to an omnect-os firmware image: | ||
1. in all files in config/ folder replace all occurrences of %% *** %% with reasonable values: | ||
1. %%CENTRIFUGO_API_KEY%%: the [API key](https://centrifugal.dev/docs/server/server_api#http-api) should come from a vault | ||
2. %%CENTRIFUGO_TOKEN_HMAC_SECRET_KEY%%: the [HMAC key](https://centrifugal.dev/docs/server/authentication) should come from a vault | ||
3. %%USER%%: user name to be matched on omnect-ui login | ||
4. %PASSWORD%%: password to be matched on omnect-ui login | ||
2. it might be reasonable to adapt other default config values to your needs | ||
3. inject config files via [omnect-cli](https://github.com/omnect/omnect-cli) to omnect-os image | ||
``` | ||
# download and copy omnect-ui docker image | ||
omnect-cli docker inject -d omnectsharedstagingacr.azurecr.io/omnect-portal-omnect-ui:latest -e /oci_images/omnect-ui.tar.gz -i my-omnect-os-image.wic | ||
# copy config files | ||
omnect-cli file copy-to-image \ | ||
-f omnect-device-service.env,factory:/etc/omnect/omnect-device-service.env \ | ||
-f omnect-ui.env,factory:/etc/omnect/omnect-ui.env \ | ||
-f publish_endpoints.json,factory:/etc/omnect/publish_endpoints.json \ | ||
-f omnect-ui.service,factory:/etc/systemd/system/omnect-ui.service \ | ||
-f create-fs-links.txt,factory:/etc/omnect/create-fs-links.txt \ | ||
-i my-omnect-os-image.wic | ||
# copy certificates | ||
# only in case not already done (e.g. device provisioned by tpm) | ||
# devices provisioned by x509 usually already have certs injected | ||
omnect-cli identity set-device-certificate \ | ||
-d "my-device-id" \ | ||
-c omnect-int-ca-iotedge-staging_fullchain.pem \ | ||
-k omnect-int-ca-iotedge-staging.key -D 365 \ | ||
-i my-omnect-os-image.wic | ||
``` | ||
|
||
## Access omnect-ui | ||
|
||
browser type: https://hostname:1977 | ||
omnect-ui can be reached at https://DeviceHostnameOrIp:1977<br> | ||
|
||
Login with the configured creadentials<br> | ||
![login](docu/login.png)<br> | ||
Watch device status<br> | ||
![login](docu/main.png) | ||
|
||
# License | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.