Skip to content

Commit

Permalink
Fix adapter react (#2843)
Browse files Browse the repository at this point in the history
  • Loading branch information
GermanBluefox authored Dec 1, 2024
1 parent 29b2f19 commit 44f0c2b
Showing 1 changed file with 127 additions and 124 deletions.
251 changes: 127 additions & 124 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,124 +1,127 @@
<img src="packages/admin/admin/admin.svg" width="100" height="100" />

# ioBroker.admin

![Number of Installations](http://iobroker.live/badges/admin-installed.svg)
![Number of Installations](http://iobroker.live/badges/admin-stable.svg)
[![NPM version](http://img.shields.io/npm/v/iobroker.admin.svg)](https://www.npmjs.com/package/iobroker.admin)

![Test and Release](https://github.com/ioBroker/ioBroker.admin/workflows/Test%20and%20Release/badge.svg)
[![Translation status](https://weblate.iobroker.net/widgets/adapters/-/admin/svg-badge.svg)](https://weblate.iobroker.net/engage/adapters/?utm_source=widget)
[![Downloads](https://img.shields.io/npm/dm/iobroker.admin.svg)](https://www.npmjs.com/package/iobroker.admin)

User interface for configuration and administration of ioBroker.

**This adapter uses Sentry libraries to automatically report exceptions and code errors to the developers.** For more details and for information how to disable the error reporting see [Sentry-Plugin Documentation](https://github.com/ioBroker/plugin-sentry#plugin-sentry)! Sentry reporting is used starting with js-controller 3.0.

## JSON config schema

The JSON config schema description can be found at [JSON config schema](/packages/jsonConfig/SCHEMA.md).

## Using common.localLink

- `%ip%` - ioBroker ip address (address of the admin)
- `%secure%` or `%protocol%` - read from `native.secure` the value and use http or https
- `%web_protocol%` - looking for the first instance of web (e.g., `web.0`) and get `native.secure` from `system.adapter.web.0`
- `%instance%` - instance of the adapter
- `%someField%` - get someField from `native` of this adapter instance
- `%web.0_bind%` - get `native.bind` from `system.adapter.web.0`
- `%native_someField%` - get someField from `native` of this adapter instance

## Scheduled restart

Some adapters are not stable or connection disappears after one or two days.
To fix this, there is a scheduled restart setting.
To activate scheduled restart, just define CRON condition when to restart adapter.

It is suggested to restart in the night, when no one use the adapter, e.g. `0 3 * * *` - at 3:00 every day.

## Let's Encrypt Certificates

To manage and update, let's encrypt certificates you need to use [`iobroker.acme`](https://github.com/iobroker-community-adapters/ioBroker.acme) adapter.

You will have so-called "collections" of certificates. Each collection has its own domains.
You can select in configuration of admin adapter if and which collection to use.

## Simple instance's settings page

The user has the possibility to limit the access to the instance configuration dialog.
For that, the option "Allow access only to specific instances" must be activated.
It could be found on the "Access to the instances" tab.
Additionally, the allowed instances should be selected in the appeared configuration table.

If this option is disabled, the simple configuration page could be accessed under `http://IP:8081/configs.html`

## Reverse proxy

Please be sure that you forward not only the http/https requests, but the web-socket traffic too. It is essential for communication.

From version 6.1.0 you have the possibility to tune intro page for usage with reverse proxy.

### Example

Your `ioBroker.admin` runs on port 8081 behind reverse proxy with domain `iobroker.mydomain.com` under path `/ioBrokerAdmin/`.
And you set up e.g., nginx to forward the requests to the `http://local-iobroker.IP:8081`.

The same is with your web instance: `https://iobroker.mydomain.com/ioBrokerWeb/ => http://local-iobroker.IP:8082`.
And with rest-api instance: `https://iobroker.mydomain.com/ioBrokerAPI/ => http://local-iobroker.IP:8093`.

You can add the following lines into Reverse Proxy tab to let Intro tab run behind reverse proxy properly:

| Global path | Instance | Instance path behind proxy |
|-------------------|---------------|----------------------------|
| `/ioBrokerAdmin/` | `web.0` | `/ioBrokerWeb/` |
| | `rest-api.0` | `/ioBrokerAPI/` |
| | `admin.0` | `/ioBrokerAdmin/` |
| | `eventlist.0` | `/ioBrokerWeb/eventlist/` |

So all links of instances that use web server, like `eventlist`, `vis`, `material` and so on will use `https://iobroker.mydomain.com/ioBrokerWeb/` path

## Used icons

This project uses icons from [Flaticon](https://www.flaticon.com/).

ioBroker GmbH has a valid license for all used icons.
The icons may not be reused in other projects without the proper flaticon license or flaticon subscription.

<!--
### **WORK IN PROGRESS**
-->
### **WORK IN PROGRESS**

- (@GermanBluefox) Changed information box on the hosts tab
- (@GermanBluefox) Corrected some errors in JsonConfig library
- (@GermanBluefox) Added flag expertMode to hide JSON config controls for non-experts

### 7.4.2 (2024-11-25)

- (@GermanBluefox) Made improvement for JSONConfig components
- (@GermanBluefox) Added clear button to text area JSON config component

### 7.4.1 (2024-11-19)

- (@GermanBluefox) Made improvement for JSONConfig components

### 7.4.0 (2024-11-17)

- (@GermanBluefox) Added new JsonConfig control: staticInfo

### 7.3.2 (2024-11-15)

- (@GermanBluefox) Some GUI packages were updated.
- (@GermanBluefox) Improved file viewer. Added icons viewer

### 7.3.1 (2024-11-14)

- (@GermanBluefox) Corrected cloud icon for admin
- (@GermanBluefox) Added old dialog names to adapter-react-v5 again
- (@GermanBluefox) Corrected the password field in JSON-Config

## License

The MIT License (MIT)

Copyright (c) 2014-2024 bluefox <[email protected]>
<img src="packages/admin/admin/admin.svg" width="100" height="100" />

# ioBroker.admin

![Number of Installations](http://iobroker.live/badges/admin-installed.svg)
![Number of Installations](http://iobroker.live/badges/admin-stable.svg)
[![NPM version](http://img.shields.io/npm/v/iobroker.admin.svg)](https://www.npmjs.com/package/iobroker.admin)

![Test and Release](https://github.com/ioBroker/ioBroker.admin/workflows/Test%20and%20Release/badge.svg)
[![Translation status](https://weblate.iobroker.net/widgets/adapters/-/admin/svg-badge.svg)](https://weblate.iobroker.net/engage/adapters/?utm_source=widget)
[![Downloads](https://img.shields.io/npm/dm/iobroker.admin.svg)](https://www.npmjs.com/package/iobroker.admin)

User interface for configuration and administration of ioBroker.

**This adapter uses Sentry libraries to automatically report exceptions and code errors to the developers.** For more details and for information how to disable the error reporting see [Sentry-Plugin Documentation](https://github.com/ioBroker/plugin-sentry#plugin-sentry)! Sentry reporting is used starting with js-controller 3.0.

## JSON config schema

The JSON config schema description can be found at [JSON config schema](/packages/jsonConfig/SCHEMA.md).

## Using common.localLink

- `%ip%` - ioBroker ip address (address of the admin)
- `%secure%` or `%protocol%` - read from `native.secure` the value and use http or https
- `%web_protocol%` - looking for the first instance of web (e.g., `web.0`) and get `native.secure` from `system.adapter.web.0`
- `%instance%` - instance of the adapter
- `%someField%` - get someField from `native` of this adapter instance
- `%web.0_bind%` - get `native.bind` from `system.adapter.web.0`
- `%native_someField%` - get someField from `native` of this adapter instance

## Scheduled restart

Some adapters are not stable or connection disappears after one or two days.
To fix this, there is a scheduled restart setting.
To activate scheduled restart, just define CRON condition when to restart adapter.

It is suggested to restart in the night, when no one use the adapter, e.g. `0 3 * * *` - at 3:00 every day.

## Let's Encrypt Certificates

To manage and update, let's encrypt certificates you need to use [`iobroker.acme`](https://github.com/iobroker-community-adapters/ioBroker.acme) adapter.

You will have so-called "collections" of certificates. Each collection has its own domains.
You can select in configuration of admin adapter if and which collection to use.

## Simple instance's settings page

The user has the possibility to limit the access to the instance configuration dialog.
For that, the option "Allow access only to specific instances" must be activated.
It could be found on the "Access to the instances" tab.
Additionally, the allowed instances should be selected in the appeared configuration table.

If this option is disabled, the simple configuration page could be accessed under `http://IP:8081/configs.html`

## Reverse proxy

Please be sure that you forward not only the http/https requests, but the web-socket traffic too. It is essential for communication.

From version 6.1.0 you have the possibility to tune intro page for usage with reverse proxy.

### Example

Your `ioBroker.admin` runs on port 8081 behind reverse proxy with domain `iobroker.mydomain.com` under path `/ioBrokerAdmin/`.
And you set up e.g., nginx to forward the requests to the `http://local-iobroker.IP:8081`.

The same is with your web instance: `https://iobroker.mydomain.com/ioBrokerWeb/ => http://local-iobroker.IP:8082`.
And with rest-api instance: `https://iobroker.mydomain.com/ioBrokerAPI/ => http://local-iobroker.IP:8093`.

You can add the following lines into Reverse Proxy tab to let Intro tab run behind reverse proxy properly:

| Global path | Instance | Instance path behind proxy |
| ----------------- | ------------- | -------------------------- |
| `/ioBrokerAdmin/` | `web.0` | `/ioBrokerWeb/` |
| | `rest-api.0` | `/ioBrokerAPI/` |
| | `admin.0` | `/ioBrokerAdmin/` |
| | `eventlist.0` | `/ioBrokerWeb/eventlist/` |

So all links of instances that use web server, like `eventlist`, `vis`, `material` and so on will use `https://iobroker.mydomain.com/ioBrokerWeb/` path

## Used icons

This project uses icons from [Flaticon](https://www.flaticon.com/).

ioBroker GmbH has a valid license for all used icons.
The icons may not be reused in other projects without the proper flaticon license or flaticon subscription.

<!--
### **WORK IN PROGRESS**
-->

### **WORK IN PROGRESS**

- (@GermanBluefox) Changed information box on the hosts tab
- (@GermanBluefox) Corrected some errors in JsonConfig library
- (@GermanBluefox) Added flag expertMode to hide JSON config controls for non-experts
- (@GermanBluefox) Corrected cloud icon for admin
- (@GermanBluefox) Added old dialog names to adapter-react-v5 again

### 7.4.2 (2024-11-25)

- (@GermanBluefox) Made improvement for JSONConfig components
- (@GermanBluefox) Added clear button to text area JSON config component

### 7.4.1 (2024-11-19)

- (@GermanBluefox) Made improvement for JSONConfig components

### 7.4.0 (2024-11-17)

- (@GermanBluefox) Added new JsonConfig control: staticInfo

### 7.3.2 (2024-11-15)

- (@GermanBluefox) Some GUI packages were updated.
- (@GermanBluefox) Improved file viewer. Added icons viewer

### 7.3.1 (2024-11-14)

- (@GermanBluefox) Corrected cloud icon for admin
- (@GermanBluefox) Added old dialog names to adapter-react-v5 again
- (@GermanBluefox) Corrected the password field in JSON-Config

## License

The MIT License (MIT)

Copyright (c) 2014-2024 bluefox <[email protected]>

0 comments on commit 44f0c2b

Please sign in to comment.