Open WorldOfGZ opened 2 days ago
There is no wrong syntax i think.
Can you try it manually?
RELEASE=$(curl -s https://api.github.com/repos/zwave-js/zwave-js-ui/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
systemctl stop zwave-js-ui
rm -rf /opt/zwave-js-ui/*
cd /opt/zwave-js-ui
wget -q https://github.com/zwave-js/zwave-js-ui/releases/download/${RELEASE}/zwave-js-ui-${RELEASE}-linux.zip
unzip -q zwave-js-ui-${RELEASE}-linux.zip
systemctl start zwave-js-ui
rm -rf /opt/zwave-js-ui/zwave-js-ui-${RELEASE}-linux.zip
rm -rf /opt/zwave-js-ui/store
@MickLesk These lines code process an update without error in console. I see this is updated in UI, but no devices appeare. probably something else wrong, maybe from my side
I tried also 2 things now :
i check it in a few minutes
No emergency. Restore helps a lot in this case :)
About my remarks "I see this is updated in UI, but no devices appear"
Could it be linked to rm -rf /opt/zwave-js-ui/store
?
It seems there are all the settings of my nodes and server here
Can you try again?
clear console first / or exit console (cache)
The update working,
But the update erase all the configuration (previous message). UI is like first configuration.
And for example /opt/zwave-js-ui/store/nodes.json
is now empty
Regarding previous message.
On Tteck script, it remove : rm -rf zwave-js-ui-${RELEASE}-linux.zip zwave-js-ui-linux store
The folder store
is coming from the extraction of the zip file.
I don't know the reason, but on the current script this is like that :
rm -rf /opt/zwave-js-ui/zwave-js-ui-${RELEASE}-linux.zip
rm -rf /opt/zwave-js-ui/store
This is clearly not the same store which is deleted, and finally all the config is deleted after update
ah thats a breaking change. You have the old files now. Its migrated to .env file with new store paths.
You can do following:
Do an Backup of your installation:
cp /opt/zwave-js-ui /opt/zwave-js-ui_bak
Remove Old Folder & Create new folder
rm -rf /opt/zwave-js-ui
mkdir -p /opt/zwave-js-ui
mkdir -p /opt/zwave_store
Move your old storage files to this path
cp /opt/zwave-js-ui/store/* /opt/zwave_store
Enter Main Folder:
cd /opt/zwave-js-ui
Update Package:
RELEASE=$(curl -s https://api.github.com/repos/zwave-js/zwave-js-ui/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
wget -q https://github.com/zwave-js/zwave-js-ui/releases/download/${RELEASE}/zwave-js-ui-${RELEASE}-linux.zip
unzip -q zwave-js-ui-${RELEASE}-linux.zip
Create .env File:
cat <<EOF >/opt/.env
ZWAVEJS_EXTERNAL_CONFIG=/opt/zwave_store/.config-db
STORE_DIR=/opt/zwave_store
EOF
Update Service
nano /etc/systemd/system/zwave-js-ui.service
Check [Service] and add or change missing:
User=root
WorkingDirectory=/opt/zwave-js-ui
ExecStart=/opt/zwave-js-ui/zwave-js-ui-linux
EnvironmentFile=/opt/.env
Check if this works. Then i write an documentation about this
Thanks for your help, it seems to be OK now.
Just some additionnal information, if you made a documentation :
Point 1, it seems I need arg -r
cp -r /opt/zwave-js-ui /opt/zwave-js-ui_bak
Point 3, I think we need to start from bak directory :
cp -r /opt/zwave-js-ui_bak/store/* /opt/zwave_store
Just to be sure, I made after an update with the script, and I have no error, and all my config
Fine, then i write tomorrow an documentation for the Migration process. Thx for Feedback 👍
Please verify that you have read and understood the guidelines.
yes
A clear and concise description of the issue.
Hello,
Just tried to update my zwave LXC using
bash -c "$(wget -qLO - https://github.com/community-scripts/ProxmoxVE/raw/main/ct/zwave-js-ui.sh)"
The script Show the ascii zwave JS UI and I have this error :
Loading... bash: -c: line 83: syntax error near unexpected token
}'`What settings are you currently utilizing?
Which Linux distribution are you employing?
Debian 11
If relevant, including screenshots or a code block can be helpful in clarifying the issue.
Please provide detailed steps to reproduce the issue.
No response