auto-updates
Audit or configure unattended upgrades on Ubuntu/Debian. Use for security-update scheduling, allowed origins and reboot policy.
How do I install this agent skill?
npx skills add https://github.com/mikr13/secure-server-setup-skills --skill auto-updatesIs this agent skill safe to install?
- Gen Agent Trust Hubpass
The skill is safe. It provides tools to audit and configure unattended upgrades on Debian-based systems. It follows security best practices such as privilege validation, restrictive file permissions, configuration integrity checks, and automated rollback mechanisms. A low-severity surface for indirect prompt injection exists due to the ingestion of system logs and configuration data.
- Socketpass
No alerts
- Snykpass
Risk: LOW · No issues
- Runlayerwarn
3/3 files flagged
What does this agent skill do?
Automatic updates
Use this skill to inspect or configure periodic upgrades. Keep the requested maintenance policy: enabling a schedule does not authorize an immediate full upgrade, automatic reboot, or removal of dependencies.
Inspect first
- Identify the distribution/release and installed
unattended-upgradesversion. Inspectapt-config dump,/etc/apt/apt.conf.d/, held packages, timers, and recent upgrade logs. - Confirm allowed origins against this distribution's installed configuration. Ubuntu security, Debian security, third-party repositories, and Ubuntu Pro/ESM have different origin requirements. Do not copy an Ubuntu origin list onto Debian.
- Record existing automatic reboot, package cleanup, notification and scheduling choices. If the request is an audit, report findings without changing them.
Configure
For operational details and lock troubleshooting, read references/apt-config.md.
-
If missing, install
unattended-upgradesusing the target's package manager within the authorized setup scope. This helper does not install packages. -
Preview scripts/setup-auto-updates.sh:
sudo bash scripts/setup-auto-updates.sh --dry-run -
Review the proposed daily periodic settings and existing origin/reboot policy. Once configuration and timer activation are authorized:
sudo bash scripts/setup-auto-updates.sh --apply --activate
The helper writes its own managed drop-in, preserves the exact previous version for rollback, validates effective APT settings, and runs an unattended-upgrade dry run. It changes no allowed origins, reboot settings, dependency cleanup, or existing notification configuration. Without --activate, timer states remain unchanged.
Verify and recover
- Check
apt-config dump, the dry-run output and allowed origins, both APT timers, their installed schedules, and recent logs. Timer presence or an active service alone is insufficient evidence of upgrades. - Plan required kernel/service restarts within the maintenance policy. Do not unhold packages without understanding why they were held.
- On failed validation or timer activation, the helper restores its prior drop-in and timer states it changed. The printed rollback directory contains the saved managed file. Restore it, or remove the new managed file if none existed, when reverting later.
- For APT contention, identify the lock holder and wait or diagnose it. Never delete lock files to bypass an active package manager.
Report configured origins, scheduling evidence, reboot policy, changes, and checks still pending on the target.
How can the creator link this skill?
Add the canonical catalog link to the repository README so users can inspect current installs and available audits. The publishing guide covers the complete discovery path.
<a href="https://skillzs.dev/skills/mikr13/secure-server-setup-skills/auto-updates">View auto-updates on skillZs</a>