Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Self hosted Management UI #20

Merged
merged 15 commits into from
Jul 1, 2024
Merged

Self hosted Management UI #20

merged 15 commits into from
Jul 1, 2024

Conversation

AllanOricil
Copy link
Owner

@AllanOricil AllanOricil commented Jun 30, 2024

All runtime Settings (Configuration) are fetched from the board at /api/v1/config.

obs: settings/config secrets are always fetched as "********". These values won't ever be exposed in the api.
obs: when submting the form it is a must to re-enter all secrets because the api doesn't update only what has was changed. I will improve this later.

image image

The same form, but served from the board

image

When submitting the form, the board's server responds as follows

image

Boostrap 5 was removed from the build to reduce the bundle size.
The size of the bundle is important because this app will
also be used as the UI for managing TOTPs in the board. Something
similar to the UI found in routers when navigating to localhost.
Moreover, the site has to be kept under 1Mb to allow the spiffs.bin
to be created and flashed in the esp32.
from a local network.

The idea is to make this behave like the UI found in routers
@AllanOricil AllanOricil force-pushed the feat/local-network-manager branch 2 times, most recently from c4c4382 to dbfcda3 Compare June 30, 2024 20:10
@AllanOricil AllanOricil changed the title Local network Management UI Self hosted Management UI Jun 30, 2024
…ile directly from the board

GET /api/v1/config and PUT /api/v1/config api routes were added to
the board's server. This will enable Users to update their config file
directly from the board.
When generating spiffs.bin with the nuxt build, the
_nuxt/build/meta/{id}.json path was too long to be included,
and the error shown in the link below was happening
https://techoverflow.net/2022/08/07/how-to-fix-spiffs_write-error-10010-unknown/
In order to fix it, I had to manually shorten the file path.
config.yml follows yaml naming conventions for properties.
so I had to convert sleepTimeout to sleep_timeout and
forceCalibration to force_calibration before serializng the json
into yaml and saving it to the SD card
@AllanOricil AllanOricil marked this pull request as ready for review July 1, 2024 14:31
@AllanOricil AllanOricil merged commit ec05d2c into main Jul 1, 2024
4 checks passed
@AllanOricil AllanOricil deleted the feat/local-network-manager branch July 1, 2024 17:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant