mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 19:11:53 +07:00
[GH-ISSUE #5686] [Feature]: Schedule node updates with timezone selection #3957
Labels
No labels
backlog
bug
clarification needed
documentation
duplicate
enhancement
github_actions
good first issue
invalid
javascript
New Feature
PR welcomed
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
MHSanaei/3x-ui#3957
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @RomanSergeev653 on GitHub (Jun 30, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/5686
Is your feature request related to a problem?
Currently, node updates can be started manually by pressing the update button. This works, but it does not allow choosing a better time for the update.
In many cases, the best time to update nodes is during low-traffic hours, for example at 03:00, when the number of active users is minimal. Updating immediately may interrupt active users or cause unnecessary downtime during peak usage.
Describe the solution you'd like
I would like to have an option to schedule node updates for a specific date and time instead of starting the update immediately.
For example, on the Nodes page, next to the existing update button, there could be an additional option such as:
When scheduling an update, the panel should allow selecting:
Timezone selection is important because the panel operator and the servers/nodes are often located in different timezones. For example, the admin may be in Europe/Berlin, while the node server may use UTC or another server-local timezone.
Ideally, the UI should clearly show which timezone is being used for the scheduled update, for example:
“Scheduled update: 03:00 Europe/Berlin”
or
“Scheduled update: 03:00 server local time”
It would also be useful to show the scheduled update status in the node list, with the ability to cancel or reschedule it before execution.
Alternatives you've considered
The current alternative is to manually log in to the panel at night and press the update button at the desired time.
Another possible workaround is using external cron jobs or scripts, but this requires additional manual setup, server access, and technical knowledge. It is also less convenient when managing multiple nodes from the panel.
Concrete use case
I manage multiple 3x-ui nodes. When a new update is available, I do not want to apply it immediately during active hours because users may be connected.
Instead, I want to schedule the update for 03:00, when the number of active users is usually minimal. Since my servers may be located in a different timezone than me, the panel should let me explicitly choose whether the scheduled time is based on my timezone, the panel timezone, or the server/node timezone.
This would make node maintenance safer and more predictable, especially for admins managing nodes in different countries or regions.
Mockups, screenshots, or examples
Example UI idea:
On the Nodes page:
Button:
Schedule update modal:
After scheduling, the node list could show:
Node-1
Scheduled update: 2026-07-01 03:00 Europe/Berlin
Actions: Cancel / Reschedule
Which parts of the panel would this affect?
Multi-node (sub-nodes)
Are you willing to help?
Before submitting
@github-actions[bot] commented on GitHub (Jun 30, 2026):
This is a valid feature request with no existing implementation in the codebase. Here is what the code currently does and what building this feature would require.
Current state (confirmed in source)
The node update path is synchronous and immediate:
POST /panel/api/nodes/updatePanelininternal/web/controller/node.go:318receives a list of node IDs and immediately callsNodeService.UpdatePanels(internal/web/service/node.go:642).UpdatePanelsiterates the given IDs, opens a gRPC connection to each reachable node, and callsremote.UpdatePanel(ctx, dev)— all within the HTTP request lifecycle.frontend/src/api/queries/useNodeMutations.ts:61via a single button infrontend/src/pages/nodes/NodeList.tsx:252.There is no deferred, queued, or time-based scheduling layer for node updates anywhere in the codebase. The cron job infrastructure in
internal/web/job/handles fixed-interval system tasks (heartbeat, traffic sync, etc.) but has no mechanism for user-defined one-off future executions.What implementing this would require
This is a non-trivial addition that touches several layers:
ScheduledNodeUpdatetable (or equivalent fields on theNodemodel) to store the target node IDs, the wall-clock execution time, the IANA timezone, and a status field (pending/running/done/cancelled). A migration ininternal/database/db.gois required.internal/web/job/) or a time.AfterFunc approach that wakes up at the scheduled time, resolves the stored UTC timestamp, and callsNodeService.UpdatePanels. The timezone only affects how the time is presented in the UI — storage in UTC is standard.frontend/src/pages/api-docs/endpoints.tsper the contribution rules.DatePickerwith timezone support viageneratePicker), plus a status column in the node list.Implementation notes for a contributor
time/tzdata(embedded zone database, available since Go 1.15 withimport _ "time/tzdata")."New Feature"and"PR welcomed"labels are available on this repo if a contributor opens a draft PR.CONTRIBUTING.md; build and test requirements are inCLAUDE.mdandMakefile(make verifyis the full gate).The request is clear and the use case is well-described. It is accepted as a backlog item; no clarification is needed.
This reply was generated automatically; a maintainer may follow up.