-
Notifications
You must be signed in to change notification settings - Fork 3
feat: add configuration option for auto update #64
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
Conversation
Signed-off-by: Derek Kaser <[email protected]>
WalkthroughThis pull request adds support for Tailscale's auto-update feature across the plugin stack. Changes include a new frontend UI function to toggle auto-update, server-side action handler in Config.php, localization entry, data model extensions to track the auto-update state, and a LocalAPI method to communicate the preference to Tailscale via PATCH request. Changes
Sequence DiagramsequenceDiagram
participant User
participant Frontend as Frontend<br/>(Tailscale.php)
participant Backend as Backend<br/>(Config.php)
participant API as LocalAPI
participant TS as Tailscale<br/>API
User->>Frontend: Click auto-update toggle
Frontend->>Frontend: Show spinner, disable controls
Frontend->>Backend: POST action=set-auto-update
Backend->>API: setAutoUpdate($enable)
API->>TS: PATCH /v0/prefs<br/>(AutoUpdate: {Apply, Set})
TS-->>API: Success
API-->>Backend: Return
Backend->>Frontend: Response
Frontend->>Frontend: Call showTailscaleConfig()
Frontend->>Frontend: Refresh UI
Frontend-->>User: Display updated state
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes
Pre-merge checks and finishing touches✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro 📒 Files selected for processing (6)
🧰 Additional context used🧬 Code graph analysis (1)src/usr/local/emhttp/plugins/tailscale/include/data/Config.php (2)
🔇 Additional comments (9)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary by CodeRabbit