-
-
Notifications
You must be signed in to change notification settings - Fork 203
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
[Bug]: install-agent.sh doesn't upgrade the agent, at least no change from hub. #469
Comments
If you use sudo systemctl restart beszel-agent.service The auto update may not work if your machine is in China because the built-in update ( I'm using rhysd/go-github-selfupdate which does not appear to support a proxy URL. I will look into forking adding support for this. |
I have machine both in and outside china. The autoupdate doesn't work on either machines. |
Okay, no worries. Let's figure this out. What happens when you run these commands? /opt/beszel-agent/beszel-agent -v /bin/sh -c '/opt/beszel-agent/beszel-agent update | grep -q "Successfully updated" && (echo "Update found, restarting beszel-agent" && systemctl restart beszel-agent) || echo "No updates found"' /opt/beszel-agent/beszel-agent -v And can you please paste the content of |
I run the three commands on the machine displayed as 0.8.0 from hub.
and I restart the
How to make the |
The auto update should restart the service if an update was found. We can run a test. First download an older version of the agent (0.9.0) and move it to curl -sL "https://github.com/henrygd/beszel/releases/download/v0.9.0/beszel-agent_$(uname -s)_$(uname -m | sed -e 's/x86_64/amd64/' -e 's/armv6l/arm/' -e 's/armv7l/arm/' -e 's/aarch64/arm64/').tar.gz" | tar -xz -O beszel-agent | tee /tmp/beszel-agent >/dev/null && chmod +x /tmp/beszel-agent
sudo mv /tmp/beszel-agent /opt/beszel-agent/beszel-agent Check that it is 0.9.0 and restart the agent. /opt/beszel-agent/beszel-agent -v
sudo systemctl restart beszel-agent.service If you pause and unpause in the hub, it should now show 0.9.0. Next we will manually run the auto update job: sudo systemctl start beszel-agent-update.service If we check the service status we should see that it ran and updated the agent: systemctl status beszel-agent-update.service
Checking the binary version again should show 0.9.1: /opt/beszel-agent/beszel-agent -v And the agent version should update in the hub by itself within one minute. If you run this and see anything different then it may be a bug. Please let me know what happens. Thanks! |
Description
daily update doesn't seem to work. Rerun the
install-agent.sh
script doesn't upgrade the agent. At least from the hub, it's still 0.8.0.I have to uninstall the agent using the install-agent.sh then reinstall it.
Expected Behavior
update the agent without uninstall
Steps to Reproduce
OS / Architecture
debian 12.9 & ubuntu 24.04
Beszel version
0.9.1 script after china-mirror patch
Installation method
Binary
Configuration
no special setting. all done by install-agent.sh script
Hub Logs
Agent Logs
The text was updated successfully, but these errors were encountered: