Hello everyone,
I’m new to openhab and I have an error that I comment on because I can’t find the solution.
After the system worked fine and after some problems I had to recover the backup of the instance through openhab-cli.
Once the instance is started, the scripts that were already created with ECMAScript (ECMA - 262 Edition 5.1) do not work.
configuration: {}
triggers:
- id: "1"
configuration:
command: OFF
itemName: rebootSystem
type: core.ItemCommandTrigger
conditions: []
actions:
- inputs: {}
id: "2"
configuration:
blockSource: <xml xmlns="https://developers.google.com/blockly/xml"><block
type="oh_script_inline" id=".6v/ADAi:,hEGp0D18i}" x="16" y="445"><field
name="inlineScript">Java.type("org.openhab.core.model.script.actions.Exec").executeCommandLine("sudo","reboot")</field></block></xml>
type: application/javascript
script: >
Java.type("org.openhab.core.model.script.actions.Exec").executeCommandLine("sudo","reboot")
type: script.ScriptAction
The first problem I found was the duplicates bundle automation addons, I fixed this with:
• sudo /bin/systemctl stop openhab.service
• sudo openhab-cli clean-cache
• sudo /bin/systemctl start openhab.service
Duplicate addons disappeared. Uninstall JavaScript Scripting and reinstall but the rules still don’t work.
The log does not indicate any errors.
Any help is welcome, thanks