Advertisement
zimniy85

50unattended-upgrades

Mar 28th, 2018
4,357
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // Unattended-Upgrade::Origins-Pattern controls which packages are
  2. // upgraded.
  3. //
  4. // Lines below have the format format is "keyword=value,...".  A
  5. // package will be upgraded only if the values in its metadata match
  6. // all the supplied keywords in a line.  (In other words, omitted
  7. // keywords are wild cards.) The keywords originate from the Release
  8. // file, but several aliases are accepted.  The accepted keywords are:
  9. //   a,archive,suite (eg, "stable")
  10. //   c,component     (eg, "main", "crontrib", "non-free")
  11. //   l,label         (eg, "Debian", "Debian-Security")
  12. //   o,origin        (eg, "Debian", "Unofficial Multimedia Packages")
  13. //   n,codename      (eg, "jessie", "jessie-updates")
  14. //     site          (eg, "http.debian.net")
  15. // The available values on the system are printed by the command
  16. // "apt-cache policy", and can be debugged by running
  17. // "unattended-upgrades -d" and looking at the log file.
  18. //
  19. // Within lines unattended-upgrades allows 2 macros whose values are
  20. // derived from /etc/debian_version:
  21. //   ${distro_id}            Installed origin.
  22. //   ${distro_codename}      Installed codename (eg, "jessie")
  23. Unattended-Upgrade::Origins-Pattern {
  24.         // Codename based matching:
  25.         // This will follow the migration of a release through different
  26.         // archives (e.g. from testing to stable and later oldstable).
  27.         // Archive or Suite based matching:
  28.         // Note that this will silently match a different release after
  29.         // migration to the specified archive (e.g. testing becomes the
  30.         // new stable).
  31.         "origin=${distro_id},archive=stable,codename=${distro_codename},label=Debian";
  32.         "origin=${distro_id},archive=stable,codename=${distro_codename},label=Debian-Security";
  33.         "origin=${distro_id},archive=stable-updates,codename=${distro_codename}-updates,label=Debian";
  34. //        "origin=${distro_id} Backports,archive=${distro_codename}-backports,codename=${distro_codename}-backports,label=Debian Backports";
  35.         "origin=Proxmox,archive=stable,codename=${distro_codename},label=Proxmox Debian repository";
  36. };
  37.  
  38. // List of packages to not update (regexp are supported)
  39. Unattended-Upgrade::Package-Blacklist {
  40. //  "vim";
  41. //  "libc6";
  42. //  "libc6-dev";
  43. //  "libc6-i686";
  44. };
  45.  
  46. // This option allows you to control if on a unclean dpkg exit
  47. // unattended-upgrades will automatically run
  48. //   dpkg --force-confold --configure -a
  49. // The default is true, to ensure updates keep getting installed
  50. Unattended-Upgrade::AutoFixInterruptedDpkg "true";
  51.  
  52. // Split the upgrade into the smallest possible chunks so that
  53. // they can be interrupted with SIGUSR1. This makes the upgrade
  54. // a bit slower but it has the benefit that shutdown while a upgrade
  55. // is running is possible (with a small delay)
  56. Unattended-Upgrade::MinimalSteps "true";
  57.  
  58. // Install all unattended-upgrades when the machine is shuting down
  59. // instead of doing it in the background while the machine is running
  60. // This will (obviously) make shutdown slower
  61. Unattended-Upgrade::InstallOnShutdown "false";
  62.  
  63. // Send email to this address for problems or packages upgrades
  64. // If empty or unset then no email is sent, make sure that you
  65. // have a working mail setup on your system. A package that provides
  66. // 'mailx' must be installed. E.g. "user@example.com"
  67. Unattended-Upgrade::Mail "root";
  68.  
  69. // Set this value to "true" to get emails only on errors. Default
  70. // is to always send a mail if Unattended-Upgrade::Mail is set
  71. Unattended-Upgrade::MailOnlyOnError "false";
  72.  
  73. // Do automatic removal of new unused dependencies after the upgrade
  74. // (equivalent to apt-get autoremove)
  75. Unattended-Upgrade::Remove-Unused-Dependencies "true";
  76.  
  77. // Automatically reboot *WITHOUT CONFIRMATION* if
  78. //  the file /var/run/reboot-required is found after the upgrade
  79. Unattended-Upgrade::Automatic-Reboot "false";
  80.  
  81. // If automatic reboot is enabled and needed, reboot at the specific
  82. // time instead of immediately
  83. //  Default: "now"
  84. Unattended-Upgrade::Automatic-Reboot-Time "06:00";
  85.  
  86. // Use apt bandwidth limit feature, this example limits the download
  87. // speed to 70kb/sec
  88. //Acquire::http::Dl-Limit "70";
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement