Documentation Index
Fetch the complete documentation index at: https://mintlify.com/CspmIT/centinela-front/llms.txt
Use this file to discover all available pages before exploring further.
Overview
The Centinela desktop application includes a built-in auto-update system that ensures you always have access to the latest features, improvements, and security patches. Updates are delivered seamlessly through GitHub releases with cryptographic signature verification.The updater uses Tauri’s official plugin (
@tauri-apps/plugin-updater) and checks for updates from the GitHub repository at https://github.com/CspmIT/mas-agua-front/releases.How Auto-Updates Work
Update Architecture
The update system follows a secure, user-friendly workflow:Security Model
Updates are secured using cryptographic signatures:- Each update bundle is signed with a private key during the build process
- The desktop application verifies signatures using the embedded public key
- Invalid or tampered updates are automatically rejected
tauri.conf.json:43):
Update Process
When a new version is available, the update process follows these steps:Update Detection
The application checks for updates by querying:This manifest contains version information and download URLs for all platform-specific bundles.
User Notification
If a newer version is found, a dialog appears:
The user can choose:
The user can choose:- Actualizar (Update): Proceed with the update immediately
- Más tarde (Later): Dismiss and update later
Download Progress
If the user approves, the update downloads with real-time progress:The progress bar shows download completion percentage.
The entire update process typically takes 1-3 minutes, depending on your internet connection speed.
Update Implementation
The update system is implemented in/home/daytona/workspace/source/src/hooks/useUpdater.js:1 using the check() and downloadAndInstall() APIs:
Checking for Updates
Download with Progress Tracking
ThedownloadAndInstall() method emits events during the download:
Error Handling
The updater includes robust error handling:Manual Update Check
By default, the application checks for updates:- On application startup
- Periodically while running (implementation-dependent)
- Open the application menu
- Navigate to Help > Check for Updates
- The updater will query GitHub and notify you of any available updates
Manual update checks use the same secure verification process as automatic checks.
Update Configuration
The update system is configured insrc-tauri/tauri.conf.json:38-44:
Configuration Options
| Option | Value | Description |
|---|---|---|
active | true | Enables the auto-update system |
endpoints | Array | URLs to check for update manifests |
dialog | true | Shows built-in update dialog (in addition to custom UI) |
pubkey | String | Public key for signature verification |
Platform-Specific Updates
The updater automatically downloads the correct bundle for your platform:- Windows
- macOS
- Linux
Bundle Type:
.msi.zipThe updater downloads and extracts the MSI installer, then runs it silently with elevated privileges if needed.Location: Updates are staged in:Troubleshooting Updates
Update Check Fails
If the application can’t check for updates: Possible Causes- No internet connection
- GitHub is unreachable
- Firewall blocking HTTPS requests
- Proxy configuration issues
Download Fails or Times Out
If the update download fails:- Check Available Disk Space: Ensure you have at least 500 MB free
- Retry the Update: Use Help > Check for Updates to try again
- Manual Download: Visit the Releases page and download/install manually
The updater has a 20-second timeout for download initiation. On slow connections, consider manual installation.
Signature Verification Fails
If you see a signature verification error: Steps to resolve:- Wait and try again later (GitHub may have had upload issues)
- Report the issue to the development team
- Download and verify the installer manually from GitHub releases
Application Won’t Relaunch
If the application fails to restart after update: WindowsUpdate Rollback
Currently, the updater does not support automatic rollback. If you experience issues after an update:Uninstall Current Version
Follow the uninstallation instructions for your platform.
Download Previous Version
Visit the Releases page and select the previous version.
Reinstall
Install the previous version following the installation guide.
Release Channels
Currently, the updater only supports the stable release channel. All updates come from official GitHub releases. Future versions may support:- Beta Channel: Early access to new features
- LTS Channel: Long-term support versions with extended maintenance
Building Update Bundles
For developers who need to create custom update bundles:Prerequisites
Install the Tauri CLI with updater support:Generate Signing Keys
Build with Updater Artifacts
Thetauri.conf.json:15 configuration enables updater artifact generation:
- Platform-specific installers (
.msi,.deb,.dmg, etc.) - Update bundles (
.msi.zip,.app.tar.gz,.AppImage.tar.gz) - Signature files (
.sig) - Update manifest (
latest.json)
Publish to GitHub Releases
The
latest.json manifest is automatically generated by Tauri CLI and includes version info, download URLs, and signatures for all platforms.Best Practices
For Users
- Keep Auto-Updates Enabled: Ensure you receive security patches promptly
- Update Promptly: Apply updates when notified to benefit from bug fixes
- Stable Internet: Ensure a stable connection before initiating updates
- Don’t Interrupt: Allow updates to complete without interrupting the process
For Administrators
- Test Updates: Test new versions in a staging environment before deploying
- Staged Rollout: For large deployments, update systems in phases
- Monitor Logs: Check update logs if issues arise
- Backup Configurations: Although configs are preserved, maintain backups
FAQ
Q: How often does the app check for updates? A: The application checks for updates on startup and may check periodically during runtime. Q: Can I disable auto-updates? A: Currently, auto-updates cannot be disabled through the UI. This ensures all users receive critical security updates. Q: Do updates require administrator privileges? A: On Windows and macOS, updates may require elevated privileges to replace application files. On Linux, it depends on the installation method (system-wide vs. user-local). Q: Will my settings be preserved after an update? A: Yes, all user data, preferences, and configurations are stored separately and persist through updates. Q: Can I update offline? A: No, updates require an internet connection to download. However, you can download installers manually and install offline. Q: What happens if an update fails? A: The current version remains installed and functional. You can retry the update or install manually.Next Steps
- Review the Installation Guide for initial setup
- Explore Desktop Application Overview for feature details
- Learn about Dashboard Configuration to customize your monitoring experience
