From a4a3de4d02010cdc7127110c6baf2073d7155193 Mon Sep 17 00:00:00 2001 From: buildmaster Date: Mon, 12 Nov 2012 10:45:47 +0100 Subject: [PATCH] initial commit --- COPYING | 339 ++++++ README | 85 ++ TODO | 3 + data/20auto-upgrades | 2 + data/20auto-upgrades-disabled | 2 + data/50unattended-upgrades.Debian | 67 ++ data/50unattended-upgrades.Ubuntu | 55 + data/logrotate.d/unattended-upgrades | 7 + debian/NEWS.Debian | 11 + debian/changelog | 988 ++++++++++++++++ debian/compat | 1 + debian/config | 7 + debian/control | 23 + debian/copyright | 12 + debian/dirs | 4 + debian/docs | 1 + debian/links | 1 + debian/po/POTFILES.in | 1 + debian/po/ca.po | 31 + debian/po/cs.po | 37 + debian/po/da.po | 38 + debian/po/de.po | 134 +++ debian/po/es.po | 65 ++ debian/po/eu.po | 38 + debian/po/fi.po | 40 + debian/po/fr.po | 39 + debian/po/it.po | 36 + debian/po/ja.po | 35 + debian/po/nl.po | 38 + debian/po/pt.po | 38 + debian/po/pt_BR.po | 40 + debian/po/ru.po | 41 + debian/po/sk.po | 29 + debian/po/sv.po | 37 + debian/po/templates.pot | 33 + debian/postinst | 66 ++ debian/postrm | 45 + debian/prerm | 45 + debian/pycompat | 1 + debian/rules | 28 + debian/templates | 17 + debian/unattended-upgrades.init | 45 + man/unattended-upgrade.8 | 57 + pm/sleep.d/10_unattended-upgrades-hibernate | 27 + po/POTFILES.in | 3 + po/da.po | 217 ++++ po/de.po | 227 ++++ po/es.po | 248 ++++ po/eu.po | 225 ++++ po/fr.po | 225 ++++ po/gl.po | 227 ++++ po/ja.po | 222 ++++ po/pt.po | 218 ++++ po/pt_BR.po | 224 ++++ po/ru.po | 224 ++++ po/sk.po | 220 ++++ po/unattended-upgrades.pot | 207 ++++ pre-build.sh | 6 + setup.cfg | 2 + setup.py | 29 + test/Makefile | 19 + .../etc/apt/apt.conf.d/50unattended-upgrades | 36 + test/aptroot/etc/apt/sources.list | 4 + test/aptroot/etc/apt/trusted.gpg | Bin 0 -> 3502 bytes test/aptroot/var/lib/dpkg/lock | 0 test/aptroot/var/lib/dpkg/status | 52 + test/aptroot/var/log/apt/history.log | 4 + test/aptroot/var/log/apt/term.log | 3 + test/aptroot/var/log/unattended-upgrades.log | 25 + test/create_debug_lock.py | 14 + test/data/50unattended-upgrades.Test | 6 + test/data/50unattended-upgrades.compat | 6 + test/data/listchanges.conf.mail | 6 + test/data/listchanges.conf.pager | 6 + test/mock-mail | 4 + test/mock-sendmail | 3 + .../conf-test-package-257-conffiles_1.deb | Bin 0 -> 1542 bytes .../conf-test-package-new-conffile_1.deb | Bin 0 -> 640 bytes ...nf-test-package-no-conffiles-anymore_2.deb | Bin 0 -> 614 bytes test/packages/conf-test-package_1.0.deb | Bin 0 -> 624 bytes test/packages/conf-test-package_1.1.deb | Bin 0 -> 618 bytes test/packages/multiple-conffiles_1_all.deb | Bin 0 -> 660 bytes test/packages/multiple-conffiles_2_all.deb | Bin 0 -> 674 bytes test/root.conffile/etc/configuration-file | 3 + test/root.conffile/etc/configuration-file1 | 3 + test/root.conffile/etc/configuration-file2 | 3 + test/root.conffile/etc/configuration-file5 | 1 + test/root.conffile/var/lib/dpkg/status | 22 + test/test_against_real_archive.py | 62 + test/test_conffile.py | 60 + test/test_in_chroot.py | 207 ++++ test/test_logdir.py | 48 + test/test_mail.py | 135 +++ test/test_minimal_partitions.py | 57 + test/test_origin_pattern.py | 121 ++ test/test_pyflakes.py | 14 + test/test_substitute.py | 39 + test/unattended_upgrade.py | 1 + unattended-upgrade | 1011 +++++++++++++++++ unattended-upgrade-shutdown | 154 +++ 100 files changed, 7542 insertions(+) create mode 100644 COPYING create mode 100644 README create mode 100644 TODO create mode 100644 data/20auto-upgrades create mode 100644 data/20auto-upgrades-disabled create mode 100644 data/50unattended-upgrades.Debian create mode 100644 data/50unattended-upgrades.Ubuntu create mode 100644 data/logrotate.d/unattended-upgrades create mode 100644 debian/NEWS.Debian create mode 100644 debian/changelog create mode 100644 debian/compat create mode 100644 debian/config create mode 100644 debian/control create mode 100644 debian/copyright create mode 100644 debian/dirs create mode 100644 debian/docs create mode 100644 debian/links create mode 100644 debian/po/POTFILES.in create mode 100644 debian/po/ca.po create mode 100644 debian/po/cs.po create mode 100644 debian/po/da.po create mode 100644 debian/po/de.po create mode 100644 debian/po/es.po create mode 100644 debian/po/eu.po create mode 100644 debian/po/fi.po create mode 100644 debian/po/fr.po create mode 100644 debian/po/it.po create mode 100644 debian/po/ja.po create mode 100644 debian/po/nl.po create mode 100644 debian/po/pt.po create mode 100644 debian/po/pt_BR.po create mode 100644 debian/po/ru.po create mode 100644 debian/po/sk.po create mode 100644 debian/po/sv.po create mode 100644 debian/po/templates.pot create mode 100644 debian/postinst create mode 100644 debian/postrm create mode 100644 debian/prerm create mode 100644 debian/pycompat create mode 100755 debian/rules create mode 100644 debian/templates create mode 100755 debian/unattended-upgrades.init create mode 100644 man/unattended-upgrade.8 create mode 100755 pm/sleep.d/10_unattended-upgrades-hibernate create mode 100644 po/POTFILES.in create mode 100644 po/da.po create mode 100644 po/de.po create mode 100644 po/es.po create mode 100644 po/eu.po create mode 100644 po/fr.po create mode 100644 po/gl.po create mode 100644 po/ja.po create mode 100644 po/pt.po create mode 100644 po/pt_BR.po create mode 100644 po/ru.po create mode 100644 po/sk.po create mode 100644 po/unattended-upgrades.pot create mode 100755 pre-build.sh create mode 100644 setup.cfg create mode 100755 setup.py create mode 100644 test/Makefile create mode 100644 test/aptroot/etc/apt/apt.conf.d/50unattended-upgrades create mode 100644 test/aptroot/etc/apt/sources.list create mode 100644 test/aptroot/etc/apt/trusted.gpg create mode 100644 test/aptroot/var/lib/dpkg/lock create mode 100644 test/aptroot/var/lib/dpkg/status create mode 100644 test/aptroot/var/log/apt/history.log create mode 100644 test/aptroot/var/log/apt/term.log create mode 100644 test/aptroot/var/log/unattended-upgrades.log create mode 100644 test/create_debug_lock.py create mode 100644 test/data/50unattended-upgrades.Test create mode 100644 test/data/50unattended-upgrades.compat create mode 100644 test/data/listchanges.conf.mail create mode 100644 test/data/listchanges.conf.pager create mode 100755 test/mock-mail create mode 100755 test/mock-sendmail create mode 100644 test/packages/conf-test-package-257-conffiles_1.deb create mode 100644 test/packages/conf-test-package-new-conffile_1.deb create mode 100644 test/packages/conf-test-package-no-conffiles-anymore_2.deb create mode 100644 test/packages/conf-test-package_1.0.deb create mode 100644 test/packages/conf-test-package_1.1.deb create mode 100644 test/packages/multiple-conffiles_1_all.deb create mode 100644 test/packages/multiple-conffiles_2_all.deb create mode 100644 test/root.conffile/etc/configuration-file create mode 100644 test/root.conffile/etc/configuration-file1 create mode 100644 test/root.conffile/etc/configuration-file2 create mode 100644 test/root.conffile/etc/configuration-file5 create mode 100644 test/root.conffile/var/lib/dpkg/status create mode 100755 test/test_against_real_archive.py create mode 100755 test/test_conffile.py create mode 100644 test/test_in_chroot.py create mode 100755 test/test_logdir.py create mode 100755 test/test_mail.py create mode 100755 test/test_minimal_partitions.py create mode 100755 test/test_origin_pattern.py create mode 100644 test/test_pyflakes.py create mode 100755 test/test_substitute.py create mode 120000 test/unattended_upgrade.py create mode 100755 unattended-upgrade create mode 100755 unattended-upgrade-shutdown diff --git a/COPYING b/COPYING new file mode 100644 index 0000000..d511905 --- /dev/null +++ b/COPYING @@ -0,0 +1,339 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. diff --git a/README b/README new file mode 100644 index 0000000..980e6e5 --- /dev/null +++ b/README @@ -0,0 +1,85 @@ +Unattended upgrades +------------------- + +This script can upgrade packages automatically and unattended. +However, it is not enabled by default. Most users enable it via the +Software Sources program (available in System/Administration). + +If you would prefer to enable it from the command line, run +"sudo dpkg-reconfigure -plow unattended-upgrades". + +It will not install packages that require dependencies that can't be +fetched from allowed origins and it will check for conffile prompts +before the install and holds back any package that requires them. + +== Setup == + +The unattended-upgrades package is normally activated by +software-properties or via debconf. By default this runs an update +every day. + +The main way to specify which packages will be auto-upgraded is by +means of their "origin" and "archive". These are taken respectively +from the Origin and Suite fields of the respository's Release file, +or can be found in the output of "apt-cache policy" in the "o" and +"a" fields for the given repository. + +The default setup auto-updates packages in the main and security +archives, which means that only stable and security updates are +applied. + +This can be changed either with the +"Unattended-Upgrade::Allowed-Origins" or the +"Unattended-Upgrade::Origins-Pattern" apt configuration lists, which +can be configured in /etc/apt/apt.conf.d/50unattended-upgrades. +Also in this file are a range of other options that can be configured. + +Allowed-Origins is a simple list of patterns of the form +"origin:archive". + +Origins-Pattern allows you to give a list of +patterns to match against. For example: + + Unattended-Upgrade::Origins-Pattern { + "origin=Google\, Inc.,suite=contrib"; + "site=www.example.com,component=main"; + }; + +will upgrade a package if either the origin is "Google, Inc." and +suite is "contrib" or if it comes from www.example.com and is in +component "main". The apt-cache policy short identifiers +(e.g. "o" for "origin") are also supported. + +All operations are be logged in /var/log/unattended-upgrades/. This +includes the dpkg output as well. + +If you want mail support you need to have a mail-transport-agent (e.g +postfix) or mailx installed. + +== Debugging == + +If something goes wrong or if you want to report a bug about the way +the script works its a good idea to run: + +$ sudo unattended-upgrade --debug --dry-run + +and look at the resulting logfile in: +/var/log/unattended-upgrades/unattended-upgrades.log +then. It will contain additional debug information. + + +== Manual Setup == + +To activate this script manually you need to ensure that the apt +configuration contains the following lines (this can be done via the +graphical "Software Source" program or via dpkg-reconfigure as well): + +APT::Periodic::Update-Package-Lists "1"; +APT::Periodic::Unattended-Upgrade "1"; + +This means that it will check for upates every day and install them +(if that is possible). If you have update-notifier installed, it will +setup /etc/apt/apt.conf.d/10periodic. Just edit this file then to fit +your needs. If you do not have this file, just create it or +create/edit /etc/apt/apt.conf - you can check your configuration by +running "apt-config dump". diff --git a/TODO b/TODO new file mode 100644 index 0000000..fbdd128 --- /dev/null +++ b/TODO @@ -0,0 +1,3 @@ +* package make have some logrotate magic in place for both + unattended-upgrades.log and unatteded-upgrades-dpkg_$(date).log +* add option to ignore trust? diff --git a/data/20auto-upgrades b/data/20auto-upgrades new file mode 100644 index 0000000..8d6d7c8 --- /dev/null +++ b/data/20auto-upgrades @@ -0,0 +1,2 @@ +APT::Periodic::Update-Package-Lists "1"; +APT::Periodic::Unattended-Upgrade "1"; diff --git a/data/20auto-upgrades-disabled b/data/20auto-upgrades-disabled new file mode 100644 index 0000000..42589c7 --- /dev/null +++ b/data/20auto-upgrades-disabled @@ -0,0 +1,2 @@ +APT::Periodic::Update-Package-Lists "0"; +APT::Periodic::Unattended-Upgrade "0"; diff --git a/data/50unattended-upgrades.Debian b/data/50unattended-upgrades.Debian new file mode 100644 index 0000000..c45f851 --- /dev/null +++ b/data/50unattended-upgrades.Debian @@ -0,0 +1,67 @@ +// Automatically upgrade packages from these origin patterns +Unattended-Upgrade::Origins-Pattern { + // Codename based matching: + // This will follow the migration of a release through different + // archives (e.g. from testing to stable and later oldstable). +// "o=Debian,n=squeeze"; +// "o=Debian,n=squeeze-updates"; +// "o=Debian,n=squeeze-proposed-updates"; +// "o=Debian,n=squeeze,l=Debian-Security"; + + // Archive or Suite based matching: + // Note that this will silently match a different release after + // migration to the specified archive (e.g. testing becomes the + // new stable). +// "o=Debian,a=stable"; +// "o=Debian,a=stable-updates"; +// "o=Debian,a=proposed-updates"; + "origin=Debian,archive=stable,label=Debian-Security"; +}; + +// List of packages to not update +Unattended-Upgrade::Package-Blacklist { +// "vim"; +// "libc6"; +// "libc6-dev"; +// "libc6-i686"; +}; + +// This option allows you to control if on a unclean dpkg exit +// unattended-upgrades will automatically run +// dpkg --force-confold --configure -a +// The default is true, to ensure updates keep getting installed +//Unattended-Upgrade::AutoFixInterruptedDpkg "false"; + +// Split the upgrade into the smallest possible chunks so that +// they can be interrupted with SIGUSR1. This makes the upgrade +// a bit slower but it has the benefit that shutdown while a upgrade +// is running is possible (with a small delay) +//Unattended-Upgrade::MinimalSteps "true"; + +// Install all unattended-upgrades when the machine is shuting down +// instead of doing it in the background while the machine is running +// This will (obviously) make shutdown slower +//Unattended-Upgrade::InstallOnShutdown "true"; + +// Send email to this address for problems or packages upgrades +// If empty or unset then no email is sent, make sure that you +// have a working mail setup on your system. A package that provides +// 'mailx' must be installed. E.g. "user@example.com" +//Unattended-Upgrade::Mail "root" + +// Set this value to "true" to get emails only on errors. Default +// is to always send a mail if Unattended-Upgrade::Mail is set +//Unattended-Upgrade::MailOnlyOnError "true"; + +// Do automatic removal of new unused dependencies after the upgrade +// (equivalent to apt-get autoremove) +//Unattended-Upgrade::Remove-Unused-Dependencies "false"; + +// Automatically reboot *WITHOUT CONFIRMATION* if a +// the file /var/run/reboot-required is found after the upgrade +//Unattended-Upgrade::Automatic-Reboot "false"; + + +// Use apt bandwidth limit feature, this example limits the download +// speed to 70kb/sec +//Acquire::http::Dl-Limit "70"; diff --git a/data/50unattended-upgrades.Ubuntu b/data/50unattended-upgrades.Ubuntu new file mode 100644 index 0000000..6412fc6 --- /dev/null +++ b/data/50unattended-upgrades.Ubuntu @@ -0,0 +1,55 @@ +// Automatically upgrade packages from these (origin:archive) pairs +Unattended-Upgrade::Allowed-Origins { + "${distro_id}:${distro_codename}-security"; +// "${distro_id}:${distro_codename}-updates"; +// "${distro_id}:${distro_codename}-proposed"; +// "${distro_id}:${distro_codename}-backports"; +}; + +// List of packages to not update +Unattended-Upgrade::Package-Blacklist { +// "vim"; +// "libc6"; +// "libc6-dev"; +// "libc6-i686"; +}; + +// This option allows you to control if on a unclean dpkg exit +// unattended-upgrades will automatically run +// dpkg --force-confold --configure -a +// The default is true, to ensure updates keep getting installed +//Unattended-Upgrade::AutoFixInterruptedDpkg "false"; + +// Split the upgrade into the smallest possible chunks so that +// they can be interrupted with SIGUSR1. This makes the upgrade +// a bit slower but it has the benefit that shutdown while a upgrade +// is running is possible (with a small delay) +//Unattended-Upgrade::MinimalSteps "true"; + +// Install all unattended-upgrades when the machine is shuting down +// instead of doing it in the background while the machine is running +// This will (obviously) make shutdown slower +//Unattended-Upgrade::InstallOnShutdown "true"; + +// Send email to this address for problems or packages upgrades +// If empty or unset then no email is sent, make sure that you +// have a working mail setup on your system. A package that provides +// 'mailx' must be installed. E.g. "user@example.com" +//Unattended-Upgrade::Mail "root" + +// Set this value to "true" to get emails only on errors. Default +// is to always send a mail if Unattended-Upgrade::Mail is set +//Unattended-Upgrade::MailOnlyOnError "true"; + +// Do automatic removal of new unused dependencies after the upgrade +// (equivalent to apt-get autoremove) +//Unattended-Upgrade::Remove-Unused-Dependencies "false"; + +// Automatically reboot *WITHOUT CONFIRMATION* if a +// the file /var/run/reboot-required is found after the upgrade +//Unattended-Upgrade::Automatic-Reboot "false"; + + +// Use apt bandwidth limit feature, this example limits the download +// speed to 70kb/sec +//Acquire::http::Dl-Limit "70"; diff --git a/data/logrotate.d/unattended-upgrades b/data/logrotate.d/unattended-upgrades new file mode 100644 index 0000000..ea865b6 --- /dev/null +++ b/data/logrotate.d/unattended-upgrades @@ -0,0 +1,7 @@ +/var/log/unattended-upgrades/unattended-upgrades*.log { + rotate 6 + monthly + compress + missingok + notifempty +} diff --git a/debian/NEWS.Debian b/debian/NEWS.Debian new file mode 100644 index 0000000..cc6b9c8 --- /dev/null +++ b/debian/NEWS.Debian @@ -0,0 +1,11 @@ +unattended-upgrades (0.50) unstable; urgency=low + + When running with the --debug switch, previous versions of + unattended-upgrades would just print what they do, but not + actually perform any dpkg actions like installing or upgrading. + + This behavior has *changed* in version 0.50 it will now + install/upgrade. There is a new option called "--dry-run" to + get this behavior back. + + -- Michael Vogt Fri, 03 Jul 2009 09:15:08 +0200 diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..a21131b --- /dev/null +++ b/debian/changelog @@ -0,0 +1,988 @@ +unattended-upgrades (0.79.3) unstable; urgency=low + + * unattended-upgrade: + - fix assert text, thanks to Niels Thykier + * really include the updated es.po, thanks to Niels Thykier + + -- Michael Vogt Tue, 07 Aug 2012 12:20:05 +0200 + +unattended-upgrades (0.79.2) unstable; urgency=low + + * use "mail -s" again to ensure there is a proper subject line when + using mailx + * do not attach headers when using mailx + * use sendmail instead of mailx when available to get a proper mime + mail with correct encoding etc (closes: #654851, #681442) + Thanks to Bjørn Mork and Teodor MICU + * po/es.po: + - updated, thanks to Omar Campagne, closes: #681334 + * debian/control: + - add suggests for mail-transport-agent + * only use ionice if available (closes: #681467) + * make pyflakes clean and add test + + -- Michael Vogt Fri, 13 Jul 2012 20:54:05 +0200 + +unattended-upgrades (0.79.1) unstable; urgency=low + + * Set apt-listchanges frontend to "mail" if sendmail is available, + the default behavior of apt-listchanges is to send a mail (if there + is a email_address in apt-listchanges.conf) even with pager/gtk + frontends so this will ensure the same behavior (closes: #579733) + * Do not use "mail -a" as this is not POSIX, instead use the python + email.Message package to construct a proper utf8 message + (closes: #654851) + + -- Michael Vogt Wed, 11 Jul 2012 22:34:14 +0200 + +unattended-upgrades (0.79) unstable; urgency=low + + [ Translation updates ] + * po/pt_BR.po: + - updated, thanks to David Prévot, closes: #678423 + * po/cs.po: + - removed, was a debconf translation + * po/ru.po: + - updated, thanks to Yuri Kozlov, closes: #678427 + * po/gl.po: + - added, thanks to Jorge Barreiro, closes: #678634 + * po/pt.po: + - added, thanks to Pedro Ribeiro, closes: #678738 + * po/sk.po: + - added, thanks to helix84, closes: #677471 + + [ Teodor MICU ] + * debian/unattended-upgrades.init: + - fixes new style lsb-init output, closes: #678030 + + [ Michael Vogt ] + * correctly detect conffile prompt for new conffiles that were + normal files previously (like /etc/profile in base-files 6.8), + closes: #673237 + * code cleanup in conffile detection and tests + * Set mail header to utf8 for the summary email (closes: #654851) + * use stdout instead of stderr in --debug mode (closes: #674140) + * data/50unattended-upgrades.{Debian,Ubuntu}: + - change default mail recipient to "root" intead of "root@localhost" + to help systems without a real mail setup (closes: #648149) + * ignore packages in the blacklist early to avoid un-upgradable warning + for mixed stable/testing systems (closes: #645382) + + -- Michael Vogt Fri, 29 Jun 2012 13:22:54 +0200 + +unattended-upgrades (0.78) unstable; urgency=low + + [ Michael Vogt ] + * data/logrotate.d/unattended-upgrades: + - simplify, thanks to Teodor MICU + * refresh po/pot automatically on clean, closes: #670473 + * po/da.po: + - updated, thanks to Joe Dalton, closes: #677804 + * po/de.po: + - updated, thanks to Chris Leick (closes: #678204) + + [ Teodor MICU ] + * debian/unattended-upgrades.init: + - use new style lsb-init output, closes: #678030 + + -- Michael Vogt Thu, 21 Jun 2012 17:05:22 +0200 + +unattended-upgrades (0.77) unstable; urgency=low + + * unattended-upgrade: + - ignore md5sum "newconffile" (LP: #936870) + - simply ignore SIGHUP instead of the setsid() magic + - redirect ionice stderr output to /dev/null to avoid + showing a error in a OpenVZ env (closes: #675021) + * unattended-upgrade-shutdown: + - be robust about import apt_pkg failures (LP: #808449), e.g. + during upgrades + - log when install finished to help track down LP #434835 + - do not log to syslog anymore as this *might* block and + could cause LP #434835 and was not working in most cases + as syslog was killed before it could log + - log instead to /var/log/unattended-upgrades-shutdown.log + to help track down LP #434835 + * debian/unattended-upgrades.init: + - add Required-{Start,Stop}: $local_fs to help track down LP #434835 + * po/fr.po: + - updated french translation (closes: #675916) + + -- Michael Vogt Mon, 11 Jun 2012 16:57:33 +0200 + +unattended-upgrades (0.76.3) unstable; urgency=low + + * unattended-upgrades: + - check if "apt.package.Version" has "policy_priority" before + using it (closes: #670131) + + -- Michael Vogt Tue, 24 Apr 2012 09:07:58 +0200 + +unattended-upgrades (0.76.2) unstable; urgency=low + + * unattended-upgrades: + - its ok if setsid fails (closes: #669583) + + -- Michael Vogt Fri, 20 Apr 2012 09:21:38 +0200 + +unattended-upgrades (0.76.1) unstable; urgency=low + + * unattended-upgrade: + - honor pin priority of < 0 when selecting new candidates + - use os.setsid() to not get killed when the terminal goes away + - only print to stdout if there is no summary mail configured + + -- Michael Vogt Thu, 19 Apr 2012 19:06:18 +0200 + +unattended-upgrades (0.76) unstable; urgency=low + + * add basic "Unattended-Upgrades::InstallOnShutdown" option to do + the install step on shutdown (closes: #652982) instead of doing + it in the backgroud while the machine is running + * test improvements + * fix mispelled "Unattended-Upgrade::MinimalSteps" (and add compat + mode) + * unattended-upgrade: + - cleanup FDs to hopefully fix zombies (closes: #646620) + + -- Michael Vogt Fri, 09 Mar 2012 09:42:33 +0100 + +unattended-upgrades (0.75.1) unstable; urgency=low + + * print conffile hold-backs to stdout to ensure its part of + the cron mail (LP: #773007), thanks to Jean-Baptiste Lallement + * unattended-upgrade: + - fix crash on automatic-reboot, thanks to Teodor (closes: #651822) + * typo fixes, thanks to Lei Zhang + + -- Michael Vogt Mon, 12 Dec 2011 14:01:41 +0100 + +unattended-upgrades (0.75) unstable; urgency=low + + * add tests for compat mode and spaces in a origin + * escape "," in the Allowed-Origins compat mode (LP: #824856) + * merged lp:~mvo/unattended-upgrades/unshadow-versions, this will + ensure that higher versions in a non-origin branch do not "shadow" + the versions from a desired origin (LP: #891747) + + -- Michael Vogt Tue, 22 Nov 2011 15:27:56 +0100 + +unattended-upgrades (0.74.4) UNRELEASED; urgency=low + + * add tests for compat mode and spaces in a origin + * escape "," in the Allowed-Origins compat mode (LP: #824856) + * merged lp:~mvo/unattended-upgrades/unshadow-versions, this will + ensure that higher versions in a non-origin branch do not "shadow" + the versions from a desired origin (LP: #891747) + + -- Michael Vogt Mon, 21 Nov 2011 18:00:57 +0100 + +unattended-upgrades (0.74.3) unstable; urgency=low + + * add missing "." to dh_installinit (closes: #648216) + + -- Michael Vogt Wed, 09 Nov 2011 20:16:12 +0100 + +unattended-upgrades (0.74.2) unstable; urgency=low + + * add missing "." to dh_installinit (closes: #648216) + + -- Michael Vogt Wed, 09 Nov 2011 19:27:43 +0100 + +unattended-upgrades (0.74.1) unstable; urgency=low + + * debian/unattended-upgrades.init: + - only run unattended-upgrades-shutdown if its actually installed + (closes: #643607) + * pm/sleep.d/10_unattended-upgrades-hibernate: + - only run shutdown helper when its available + * updated README and defaults based on the work from + Reuben Thomas, many thanks (closes: #632336) + * lintian fixes + * debian/rules, debian/unattended-upgrades.init: + - fix dh_initallinit arguments (closes: #630732) + + -- Michael Vogt Wed, 09 Nov 2011 09:26:56 +0100 + +unattended-upgrades (0.74) unstable; urgency=low + + * test improvements + * fix crash when no packages are upgraded + * only run dpkg if there are packages to upgrade (closes: #647476) + * include "stable-updates" in the configuration example + * debian/po/de.po: + - updated, thanks to Helge Kreutzmann (closes: #647172) + * debian/rules: + - install initscripts but do not run them on install/upgrade + (closes: #645919), thanks to Teodor MICU + * data/50unattended-upgrades.Debian: + - update default Debian config for squeeze, thanks to + John Feuerstein for the example (closes: #609854) + * debian/prerm: + - ignore failures from versions where the initscript is run + with "stop" even when not in shutdown mode (closes: #645919) + * unattended-upgrade: + - ensure to release shutdown-lock before shutting down + (closes: #645919) + * debian/postinst, data/20auto-upgrades-disabled: + - allow disabling via debconf (closes: #645971) + + -- Michael Vogt Tue, 08 Nov 2011 17:37:31 +0100 + +unattended-upgrades (0.73.1) unstable; urgency=low + + [ Michael Vogt ] + * unattended-upgrade: + - re-eval pkgs_kept_back after a successful upgrade to ensure + that its in sync with the cache (closes: #639840), thanks to + Iain Nicol + - do not write dpkg terminal log in --dry-run mode instead just + output to stdout (closes: #640329) + * test/test_origin_pattern.py: + - test fixes + + [ Peter Eisentraut ] + * debian/unattended-upgrade.init: + - add support for "status" action + + [ Iain Nicol ] + * unattended-upgrade: + - ensure pkgs_to_upgrade stays sorted and fix crash + + -- Michael Vogt Wed, 19 Oct 2011 15:16:20 +0200 + +unattended-upgrades (0.73ubuntu1) oneiric; urgency=low + + * debian/po/de.po: + - updated, closes: #631316 (thanks to Helge Kreutzmann) + * merged lp:~brian-murray/unattended-upgrades/init-eol, this + makes the shutdown message nicer, thanks to Brian Murray + * unattended-upgrade: + - write progress information /var/run/unattended-upgrades.progres + so that the progress can be displayed on shutdown + * unattended-upgrade-shutdown: + - show install progress during shutdown + * po/unattended-upgrades.pot: + - refresh + * unattended-upgrade: + - Do not upgrade apps if "XB-Upgrade-Requires: app-restart" + is set in the debian/control file. + This can be override with the option: + Unattended-Upgrade::IgnoreAppsRequireRestart=true + + -- Michael Vogt Tue, 19 Jul 2011 16:44:51 +0200 + +unattended-upgrades (0.72.3) unstable; urgency=low + + * debian/rules: + - run the original targets after override_dh_ + * test/create_debug_lock.py, unattended-upgrade: + - fix two missing python-apt 0.8 transition issues + (thanks to Reinhard Tartler, closes: #630192) + + -- Michael Vogt Thu, 16 Jun 2011 09:13:49 +0200 + +unattended-upgrades (0.72.2) unstable; urgency=low + + * po/fr.po: + - updated, thanks to to Steve Petruzzello (closes: #622718) + * debian/po/ca.po: + - added, thanks to Innocent De Marchi (closes: #628368) + * unattended-upgrade: + - fix conffile prompt detection (closes: #624148) + * debian/rules, debian/control: + - move to dh7 + * work with python-apt 0.8 (closes: #630192) + * switch to dh_python2 + + -- Michael Vogt Wed, 15 Jun 2011 09:50:25 +0200 + +unattended-upgrades (0.72.1ubuntu1) natty; urgency=low + + * unattended-upgrade: + - fix detection of unclean dpkg state if another package manager + is working (LP: #754330) + + -- Michael Vogt Tue, 12 Apr 2011 10:34:42 +0200 + +unattended-upgrades (0.72ubuntu1) natty; urgency=low + + * unattended-upgrade, data/50unattended-upgrades.{Debian,Ubuntu}: + - automatically fix a interrupted dpkg (e.g. from a powerfailure) + (LP: #584817) + - add Unattended-Upgrade::AutoFixInterruptedDpkg to allow the admin + to configure this option + + -- Michael Vogt Thu, 07 Apr 2011 11:43:26 +0200 + +unattended-upgrades (0.71ubuntu1) natty; urgency=low + + * debian/po/da.po: + - added, thanks toJoe Dalton (closes: #619320) + * unattended-upgrade, test/test_conffile.py: + - use apt_inst.DebFile.control.extractdata() instead of + apt_inst.debExtractControl() to not hit the limit of the + tag section parser (LP: #724994) + - add regression test + + -- Michael Vogt Wed, 06 Apr 2011 11:44:48 +0200 + +unattended-upgrades (0.70ubuntu1) natty; urgency=low + + * merged lp:~mvo/unattended-upgrades/minimal-steps-upgrade + - This allows performaing the upgrades in minimal chunks so + that they can be interrupted (relatively) quickly with + SIGUSR1 + - This feature is not enabled by default yet, in order + to use it, uncomment the line in 50unattended-upgrades: + Unattended-Upgrades::MinimalSteps "true"; + LP: #729214 + + -- Michael Vogt Mon, 14 Mar 2011 11:49:02 +0100 + +unattended-upgrades (0.70) unstable; urgency=low + + * pm/sleep.d/10_unattended-upgrades-hibernate: + - remove some unneeded lines from the script, thanks to + Seth Arnold (LP: #595792) + * test/test_mail.py: + - add tests for apt-listchanges.conf parser + * unattended-upgrade: + - add new Unattended-Upgrade::Origins-Pattern option that is much + more flexible than the previous Allowed-Origins. It supports + match patterns like: + "origin=Debian,label=Debian-Security,component=main" + "site=security.debian.org" + - add support for escaping, so "origin=Google\, Inc,suite=stable" + is possible (thanks to Alexander Reichle-Schmehl), closes: #609876 + - do not send a summary mail in --dry-run mode (closes: #609516) + * make Package-Blacklist a regexp (thanks to Raymond Lee) and add + test + * README: + - fixed outdated ubuntu centric info (closes: #611675) + * po/fr.po: + - updated, thanks to Steve Petruzzello (closes: #597606) + * data/50unattended-upgrades.Debian: + - add oldstable example (closes: #515980) + * test/test_against_real_archive.py, test/aptroot: + - add regression test that talks against the real archive + * unattended-upgrade: + - remove MyCache, apt.Cache has all the features we need + - add rootdir option to better support automatic testing + * unattended-upgrade: + - create logdir based on configuration, thanks to Arno Schuring + (closes: #615486) + - support Unattended-Upgrade::Log{Dir,File} as a config option, but + keep APT::UnattendedUpgrades::Log{Dir,File} for compatiblity + * test/test_logdir.py: + - add test for _setup_logging + + -- Michael Vogt Fri, 04 Mar 2011 13:17:39 +0100 + +unattended-upgrades (0.65ubuntu2) natty; urgency=low + + * add missing lsb-release build-depends + + -- Michael Vogt Fri, 07 Jan 2011 19:00:05 +0100 + +unattended-upgrades (0.65ubuntu1) natty; urgency=low + + [ Michael Vogt ] + * debian/po/pt_BR.po: + - updated, thanks to Adriano Rafael Gomes (closes: #607403) + * debian/rules: + - use different template depending on the build host + (ubuntu,debian) + - remove obsolete arch-build target + * data/50unattended-upgrades.Debian: + - add debian specific template + + [ Nobuto MURATA ] + * data/50unattended-upgrades.Ubuntu: + - adapt repository format for Ubuntu, LP: #691886 + + -- Michael Vogt Fri, 07 Jan 2011 15:57:20 +0100 + +unattended-upgrades (0.64ubuntu1) natty; urgency=low + + * debian/postinst: + - fixup incorrect LSB Default-Start and Stop values + + -- Michael Vogt Thu, 18 Nov 2010 09:35:39 +0100 + +unattended-upgrades (0.63ubuntu1) natty; urgency=low + + * debian/unattended-upgrades.init: + - fix default stop value, thanks to Petter Reinholdtsen, + closes: #593987 + * unattended-upgrade: + - add new Unattended-Upgrade::MailOnlyOnError option that will + make the script only send a mail when a error occured (thanks + to Steffen Kittel) + * test/test_mail.py: + - add test for Unattended-Upgrade::MailOnlyOnError feature + * README: + - improve description for the Allowed-Origins option + * test/Makefile: + - run test on bzr-buildpackage and fail if one of the tests + fail + + -- Michael Vogt Wed, 10 Nov 2010 15:18:37 +0100 + +unattended-upgrades (0.62.2) unstable; urgency=low + + * debian/postinst: + - add fixup code for installs with incorrect values from + the stop value (really closes: #593987), thanks to + Peter Reinholdtsen + + -- Michael Vogt Thu, 18 Nov 2010 09:00:44 +0100 + +unattended-upgrades (0.62.1) unstable; urgency=low + + * debian/unattended-upgrades.init: + - fix default stop value, thanks to Petter Reinholdtsen, + closes: #593987 + + -- Michael Vogt Wed, 17 Nov 2010 21:26:10 +0100 + +unattended-upgrades (0.62ubuntu1) maverick; urgency=low + + * merged fixes from debian/sid, notably allowing ":" + as seperator for (origin, archive) + + -- Michael Vogt Thu, 26 Aug 2010 18:45:07 +0200 + +unattended-upgrades (0.62) unstable; urgency=low + + [ Michael Vogt ] + * updated Russian program translation, thanks to + Yuri Kozlov, closes: #592646 + * updated pt_BR translations, thanks to Sergio Cipolla, + closes: #593755 + + [ Alex Owen ] + * allow ":" as seperator in Unattended-Upgrade::Allowed-Origins + (closes: #536754) + + -- Michael Vogt Thu, 26 Aug 2010 18:41:06 +0200 + +unattended-upgrades (0.61) unstable; urgency=low + + * merged changes from the ubuntu branch + + -- Michael Vogt Mon, 02 Aug 2010 12:10:00 +0200 + +unattended-upgrades (0.60ubuntu3) maverick; urgency=low + + * merged changes from debian-sid + * fix crash when the old package had a conffile but that + disappears in the new pacakge + + -- Michael Vogt Mon, 02 Aug 2010 12:08:21 +0200 + +unattended-upgrades (0.60ubuntu2) maverick; urgency=low + + * debian/control: + - add missing lsb-release dependency + * debian/control: + - depend on python-apt (>= 0.7.90) + * unattended-upgrade: + - port to python-apt 0.8 API + + -- Michael Vogt Mon, 02 Aug 2010 10:29:46 +0200 + +unattended-upgrades (0.60ubuntu1) maverick; urgency=low + + * Include reboot required notification in sent emails (LP: #415202) + and add test for it (thanks to Paul Elliott for the initial patch) + * allow ${distro_id} and ${distro_codename} in + Unattended-Upgrade::Allowed-Origins and update conffile to it + + -- Michael Vogt Mon, 17 May 2010 15:19:21 +0200 + +unattended-upgrades (0.55ubuntu4) lucid-proposed; urgency=low + + * unattended-upgrade: + - fix rewind_cache if a pkg fails to get marked for upgrade + (LP: #571734) + + -- Michael Vogt Thu, 29 Apr 2010 16:39:45 +0200 + +unattended-upgrades (0.55ubuntu3) lucid; urgency=low + + [ Michael Vogt ] + * add Vcs-Bzr header + * unattended-upgrade-shutdown: + - add information to plymouth shutdown screen if a + unattended-upgrade is in progress (LP: #506709) + + [ Loïc Minier ] + * Fix typo in README. + + -- Michael Vogt Wed, 17 Mar 2010 17:47:08 +0100 + +unattended-upgrades (0.55ubuntu2) lucid; urgency=low + + * Suggest bsd-mailx instead of mailx as mailx is a transitional package. + + -- Loïc Minier Thu, 21 Jan 2010 10:25:12 +0100 + +unattended-upgrades (0.55ubuntu1) lucid; urgency=low + + * updated for lucid + * add new "Unattended-Upgrade::Remove-Unused-Dependencies" + option that is off by default to allow removal of new unused + dependencies + * data/50unattended-upgrades: + - add example setting for the apt bandwidth limit option + (closes: #557258) + * fix bug in conffile prompt check (LP: #336558) + * lintian fixes + + -- Michael Vogt Fri, 15 Jan 2010 13:27:53 +0100 + +unattended-upgrades (0.52ubuntu1) karmic; urgency=low + + * Add new option "Unattended-Upgrade::Automatic-Reboot" that + will automatically reboot without confirmation if the upgrade + requires a reboot (off by default) LP: #400018 + * fix typo in filename (LP: #397810) + + -- Michael Vogt Mon, 20 Jul 2009 13:36:14 +0200 + +unattended-upgrades (0.51ubuntu1) karmic; urgency=low + + * unattended-upgrade-shutdown: + - deal with syslog not avaiable (LP: #396263) + * pm/sleep.d/10_unatteded-upgrades-hibernate: + - add script to ensure that installing is finished when + hibernating (LP: #191514) + + -- Michael Vogt Fri, 10 Jul 2009 10:20:47 +0200 + +unattended-upgrades (0.50ubuntu2) karmic; urgency=low + + * Add sanity-check on clean to prevent uploads with Python syntax errors. + * Fix syntax error in unattended-upgrades-shutdown (LP: #396134). + + -- Colin Watson Mon, 06 Jul 2009 17:34:25 +0100 + +unattended-upgrades (0.50ubuntu1) karmic; urgency=low + + * fix crash in ouput, thanks to Joerg Schuetter, closes: #535347 + * when running in --debug mode, also print debug output to stderr + * add --dry-run option to simulate a run, but not actually install + something + * when running with --debug, install packages instead of just + simulating the install, --dry-run is avaialble for simulation + * check for packages on hold and do not upgrade them (closes: #511677) + * deal better with failures in pkgname_from_deb() (LP: #305046) + * improved the README some more (LP: #311052) + * fix locking problem (LP: #359010) + * Contain unattended-upgrades log in the status mail as well + (LP: #245422) + * ensure that unattended-upgrade is finished on shutdown + (LP: #191514) + + -- Michael Vogt Mon, 06 Jul 2009 09:26:48 +0200 + +unattended-upgrades (0.42ubuntu1) karmic; urgency=low + + * debian/po/sk.po: + - new translation, thanks to helix84, closes: #532959 + * debian/po/ru.po: + - updated, thanks to Yuri Kozlov, closes: #527111 + * debian/po/eu.po: + - updated, thanks to Piarres Beobide, closes: #513436 + * debian/links + - add symlink to make binary name and package name match, + closes: #428965 + + -- Michael Vogt Tue, 16 Jun 2009 11:52:32 +0200 + +unattended-upgrades (0.42debian2) UNRELEASED; urgency=low + + * apply patch by Julian Andres Klode to move to the new + python-apt 0.8 API (closes: #572088) + + -- Michael Vogt Wed, 21 Apr 2010 10:19:05 +0200 + +unattended-upgrades (0.42debian1) unstable; urgency=low + + * debian/po/sk.po: + - new translation, thanks to helix84, closes: #532959 + * debian/po/ru.po: + - updated, thanks to Yuri Kozlov, closes: #527111 + * debian/po/eu.po: + - updated, thanks to Piarres Beobide, closes: #513436 + * debian/links + - add symlink to make binary name and package name match, + closes: #428965 + + -- Michael Vogt Thu, 25 Jun 2009 16:07:29 +0200 + +unattended-upgrades (0.41ubuntu1) karmic; urgency=low + + * fix lintian warnings + * add man-page (closes: #394277) + * debian/po/cs.po: + - updated Czech translation (thanks to Vítězslav Kotrla) + closes: #532136 + * add kept back packages to the status email (thanks to + Maximilian Gaukler, closes: #526505) + + -- Michael Vogt Mon, 15 Jun 2009 10:27:51 +0200 + +unattended-upgrades (0.41debian1) unstable; urgency=low + + * fix lintian warnings + * add man-page (closes: #394277) + * debian/po/cs.po: + - updated Czech translation (thanks to Vítězslav Kotrla) + closes: #532136 + * add kept back packages to the status email (thanks to + Maximilian Gaukler, closes: #526505) + + -- Michael Vogt Wed, 10 Jun 2009 20:36:39 +0200 + +unattended-upgrades (0.40ubuntu1) karmic; urgency=low + + * data/50unattended-upgrades: + - updated for karmic + * unattended-upgrade: + - use the new python-apt API to avoid deprecation + warnings + * debian/control: + - update depends on python-apt to (>= 0.7.9) + + -- Michael Vogt Wed, 06 May 2009 21:54:16 +0200 + +unattended-upgrades (0.40debian1) unstable; urgency=low + + * unattended-upgrade: + - use the new python-apt apt.Package.Version class when + checking for the candidate origin (closes: #526791) + * data/50unattended-upgrades: + - updated for squeeze + + -- Michael Vogt Wed, 06 May 2009 08:18:50 +0200 + +unattended-upgrades (0.39debian1) unstable; urgency=low + + * Merging new Ubuntu release + + -- Michael Vogt Tue, 03 Mar 2009 08:38:08 +0100 + +unattended-upgrades (0.39) jaunty; urgency=low + + * debian/po/fr.po: + - updated french translation (closes: #511373) + * debian/po/es.po: + - added spanish translation (closes: #512213) + * fix crash in rewind_packages (closes: #517510) + * debian/rules: + - add --install-layout=deb to avoid that the binaries and + the locales get installed into /usr/local + + -- Michael Vogt Mon, 02 Mar 2009 10:51:23 +0100 + +unattended-upgrades (0.38) jaunty; urgency=low + + * debian/po: + - add ru.po debian template (closes: #509032) + - add eu.po debian template (closes: #508983) + - add fr.po debian template (closes: #508389) + - add ja.po debian template (closes: #509343) + - add fi.po debian template (closes: #509370) + * po/eu.po: + - added eu.po translation (closes: #508984) + - added ja.po translation (closes: #509748) + + -- Michael Vogt Sat, 05 Jan 2009 10:38:34 +0100 + +unattended-upgrades (0.37debian1) unstable; urgency=low + + * debian/po: + - add ru.po debian template (closes: #509032) + - add eu.po debian template (closes: #508983) + - add fr.po debian template (closes: #508389) + - add ja.po debian template (closes: #509343) + - add fi.po debian template (closes: #509370) + * po/eu.po: + - added eu.po translation (closes: #508984) + - added ja.po translation (closes: #509748) + + -- Michael Vogt Mon, 05 Jan 2009 10:34:14 +0100 + +unattended-upgrades (0.37) jaunty; urgency=low + + * better debconf template and description (thanks to the + debian-l10 team (closes: #508136) + * debian/po/sv.po: + - add sv.po debian template (closes: #508225) + * debian/po/it.po: + - add it.po debian template (closes: #508193) + * debian/po/ja.po: + - add ja.po debian template (closes: #508564) + * debian/po/de.po: + - add de.po debian template (closes: #508481) + * po/fr.po: + - add fr.po translation (closes: #508390) + * po/cs.po: + - add cs.po translation (closes: #508702) + * po/pt.po: + - add pt.po translation (closes: #508705) + * unattended-upgrade: + - better default permissions of the install log + (closes: #507638) + - only disable apt-listchanges if it is not set to + 'mail' (closes: #507639) + + -- Michael Vogt Mon, 15 Dec 2008 09:46:42 +0100 + +unattended-upgrades (0.36debian1) unstable; urgency=low + + * merge from ubuntu: + * make cache calculations quicker (thanks to Ben Hutchings, + closes #475610) + * add hostname in mail header, thanks to Arthur de Jong + (closes: #502171, LP: #245417) + * better email summary of the performed actions + (closes: #502351) + * be more robust against failures to read the deb (LP: #227448) + * better debconf template and description (thanks to the + debian-l10 team (closes: #508136) + * debian/po/sv.po: + - add sv.po debian template (closes: #508225) + * debian/po/it.po: + - add it.po debian template (closes: #508193) + * debian/po/ja.po: + - add ja.po debian template (closes: #508564) + * debian/po/de.po: + - add de.po debian template (closes: #508481) + * po/fr.po: + - add fr.po translation (closes: #508390) + * po/cs.po: + - add cs.po translation (closes: #508702) + * po/pt.po: + - add pt.po translation (closes: #508705) + * unattended-upgrade: + - better default permissions of the install log + (closes: #507638) + - only disable apt-listchanges if it is not set to + 'mail' (closes: #507639) + + -- Michael Vogt Tue, 09 Dec 2008 01:45:31 +0100 + +unattended-upgrades (0.36) jaunty; urgency=low + + * make cache calculations quicker (thanks to Ben Hutchings, + closes #475610) + * add hostname in mail header, thanks to Arthur de Jong + (closes: #502171, LP: #245417) + * better email summary of the performed actions + (closes: #502351) + * be more robust against failures to read the deb (LP: #227448) + + -- Michael Vogt Wed, 26 Nov 2008 21:31:42 +0100 + +unattended-upgrades (0.35debian1) unstable; urgency=low + + * merge from ubuntu (new upstream release) + * add debconf prompt (priority medium) that asks if auto + updates should be enabled + + -- Michael Vogt Wed, 26 Nov 2008 10:46:08 +0100 + +unattended-upgrades (0.35) jaunty; urgency=low + + * updated for jaunty + * improved README to make it clerer where the values of + (origin, archive) come from (thanks to + + -- Michael Vogt Wed, 26 Nov 2008 10:44:31 +0100 + +unattended-upgrades (0.32ubuntu2) intrepid; urgency=low + + * Updated for intrepid (and updated gutsy references too!) + + -- Sarah Hobbs Mon, 13 Oct 2008 22:40:21 +1100 + +unattended-upgrades (0.32ubuntu1) intrepid; urgency=low + + * Add debconf question to ask whether automatic updates should be configured + by default: add debconf template, postinst and postrm scripts that uses + ucf to manage /etc/apt/apt.conf.d/20auto-upgrades since we don't want to + enable automatic updates by default. (LP: #84918) + + -- Mathias Gug Wed, 08 Oct 2008 21:01:52 -0400 + +unattended-upgrades (0.31ubuntu1) intrepid; urgency=low + + [ Michael Vogt ] + * fix i18n and add build-dependency to python-distutils-extra + + [ Brian Murray ] + * string fix for "Automatically" in 50unattended-upgrades (LP: #209049) + + -- Michael Vogt Wed, 23 Jul 2008 19:39:05 +0200 + +unattended-upgrades (0.30ubuntu1) hardy; urgency=low + + [ John Edwards ] + * fix missing spaces in the log file (LP: #136452) + * add better comments and examples to data/50unattended-upgrades + + [ Michael Vogt ] + * README improved based on Johns suggestions (thanks!) + * fix grammer and dated reference to dapper (LP: #140038), + thanks to Christer Edwards for the suggestions + * add "mailx" to suggests (LP: #137994) + * show propper log output if mail is not available (LP: #137994) + * show packages that are held back from the upgrade because of + conffile prompt in the log as a warning (LP: #133551) + * create logdir if it does not exist (LP: #87338) + * fix error when installing from file:// uris (LP: #56832) + + -- Michael Vogt Mon, 10 Mar 2008 11:57:17 +0100 + +unattended-upgrades (0.26ubuntu1) hardy; urgency=low + + * updated for hardy + + -- Michael Vogt Tue, 05 Feb 2008 13:36:18 +0100 + +unattended-upgrades (0.25.3ubuntu1) gutsy; urgency=low + + * merged patch from Tuomas Jormola to detect if + dpkg --force-conf(new|old) is set (LP: #135247) + + -- Michael Vogt Tue, 11 Sep 2007 21:37:13 +0200 + +unattended-upgrades (0.25.2ubuntu1) gutsy; urgency=low + + * do not run with broken cache + * use ubuntu version number to keep auto-sync from coming for us + + -- Michael Vogt Wed, 11 Jul 2007 11:19:49 +0100 + +unattended-upgrades (0.25.1debian1-0.1) unstable; urgency=low + + * Non-Maintainter Update (BSP) + * Add dependency on apt (>=0.7) + (closes: #475611) + + -- Bas Zoetekouw Sat, 14 Jun 2008 14:55:51 +0200 + +unattended-upgrades (0.25.1debian1) unstable; urgency=low + + * documentation updated + + -- Michael Vogt Thu, 07 Jun 2007 13:36:47 +0200 + +unattended-upgrades (0.25.1) gutsy; urgency=low + + * documentation updated + + -- Michael Vogt Fri, 08 Jun 2007 14:50:10 +0200 + +unattended-upgrades (0.25ubuntu1) gutsy; urgency=low + + * updated for gutsy + + -- Michael Vogt Wed, 16 May 2007 15:21:11 +0200 + +unattended-upgrades (0.24debian1) unstable; urgency=low + + * new upstream version + + -- Michael Vogt Tue, 24 Apr 2007 23:34:15 +0200 + +unattended-upgrades (0.23ubuntu3) feisty-proposed; urgency=low + + * added missing README (thanks to siretart, LP#109564) + + -- Michael Vogt Tue, 24 Apr 2007 11:26:48 +0200 + +unattended-upgrades (0.22ubuntu2) feisty; urgency=low + + * fail if not runing as root (LP#72514) + * do not crash if a archive can not be found (LP#72249) + + -- Michael Vogt Thu, 22 Mar 2007 17:14:47 +0100 + +unattended-upgrades (0.22ubuntu1) feisty; urgency=low + + * be more careful about checking if we actually have a + candidateOrigin (lp: #81055) + + -- Michael Vogt Tue, 23 Jan 2007 11:38:44 +0100 + +unattended-upgrades (0.22ubuntu0) feisty; urgency=low + + * improved the description + * added "Unattended-Upgrade::Mail" mail notification + + -- Michael Vogt Fri, 8 Dec 2006 22:40:42 +0100 + +unattended-upgrades (0.21ubuntu0) feisty; urgency=low + + * data/50unattended-upgrades: + - updated for feisty + + -- Michael Vogt Fri, 3 Nov 2006 22:31:02 +0100 + +unattended-upgrades (0.2) unstable; urgency=low + + * initial debian upload + + -- Michael Vogt Mon, 2 Oct 2006 11:06:50 +0200 + +unattended-upgrades (0.1ubuntu6) edgy; urgency=low + + * debian/control: + - only depend on python-apt + + -- Michael Vogt Thu, 27 Jul 2006 15:03:46 +0200 + +unattended-upgrades (0.1ubuntu5) edgy; urgency=low + + * data/apt-check.py: + - fix in the clear() method + * data/50unattended-upgrades: + - updated to include edgy as default + + -- Michael Vogt Tue, 4 Jul 2006 11:23:09 +0200 + +unattended-upgrades (0.1ubuntu4) edgy; urgency=low + + * added misssing apt-utils dependency + + -- Michael Vogt Tue, 27 Jun 2006 09:36:43 +0200 + +unattended-upgrades (0.1ubuntu3) dapper; urgency=low + + * debian/dirs: /etc/apt.conf.d -> /etc/apt/apt.conf.d (Ubuntu: #44172) + + -- Michael Vogt Mon, 29 May 2006 08:34:08 +0200 + +unattended-upgrades (0.1ubuntu2) dapper; urgency=low + + * unattended-upgrade: + - fix log output (ubuntu: #43773) + - fix configuration by providing a example config (ubuntu: #43778) + + -- Michael Vogt Wed, 10 May 2006 20:20:54 +0200 + +unattended-upgrades (0.1ubuntu1) dapper; urgency=low + + * work with the latest python-apt api (ubuntu: #38958) + + -- Michael Vogt Mon, 8 May 2006 17:28:38 +0200 + +unattended-upgrades (0.0+bzr20051201) dapper; urgency=low + + * initial version + + -- Michael Vogt Mon, 28 Nov 2005 17:04:41 +0100 diff --git a/debian/compat b/debian/compat new file mode 100644 index 0000000..c793025 --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +7 \ No newline at end of file diff --git a/debian/config b/debian/config new file mode 100644 index 0000000..5be917b --- /dev/null +++ b/debian/config @@ -0,0 +1,7 @@ +#!/bin/sh -e + +# Source debconf library. +. /usr/share/debconf/confmodule + +db_input medium unattended-upgrades/enable_auto_updates || true +db_go diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..ada358f --- /dev/null +++ b/debian/control @@ -0,0 +1,23 @@ +Source: unattended-upgrades +Section: admin +Priority: optional +Maintainer: Michael Vogt +Build-Depends: debhelper (>= 7.0.50~), po-debconf, lsb-release +Build-Depends-Indep: python (>= 2.6.6-3~), python-distutils-extra +Standards-Version: 3.8.3 +Vcs-Bzr: http://code.launchpad.net/~ubuntu-core-dev/unattended-upgrades/ubuntu/ + +Package: unattended-upgrades +Architecture: all +Depends: ${shlibs:Depends}, ${misc:Depends}, debconf, python, + python-apt (>= 0.7.90), apt-utils, apt, ucf, lsb-release, + lsb-base (>= 3.2-14) +Suggests: bsd-mailx, mail-transport-agent +Description: automatic installation of security upgrades + This package can download and install security upgrades automatically + and unattended, taking care to only install packages from the + configured APT source, and checking for dpkg prompts about + configuration file changes. + . + This script is the backend for the APT::Periodic::Unattended-Upgrade + option. diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..4471469 --- /dev/null +++ b/debian/copyright @@ -0,0 +1,12 @@ +This package was debianized by Michael Vogt on +Mon, 28 Nov 2005 17:01:41 +0100. + +It was downloaded via bzr from +http://code.launchpad.net/~ubuntu-core-dev/unattended-upgrades/ubuntu + +Copyright: 2005-2009 Canonical Ltd + +Upstream Author: Michael Vogt + +GPL, see /usr/share/common-licenses/GPL-2 + diff --git a/debian/dirs b/debian/dirs new file mode 100644 index 0000000..59b8881 --- /dev/null +++ b/debian/dirs @@ -0,0 +1,4 @@ +usr/bin +var/log/unattended-upgrades +etc/logrotate.d +etc/apt/apt.conf.d diff --git a/debian/docs b/debian/docs new file mode 100644 index 0000000..100b938 --- /dev/null +++ b/debian/docs @@ -0,0 +1 @@ +README \ No newline at end of file diff --git a/debian/links b/debian/links new file mode 100644 index 0000000..8dfd2fa --- /dev/null +++ b/debian/links @@ -0,0 +1 @@ +usr/bin/unattended-upgrade usr/bin/unattended-upgrades \ No newline at end of file diff --git a/debian/po/POTFILES.in b/debian/po/POTFILES.in new file mode 100644 index 0000000..cef83a3 --- /dev/null +++ b/debian/po/POTFILES.in @@ -0,0 +1 @@ +[type: gettext/rfc822deb] templates diff --git a/debian/po/ca.po b/debian/po/ca.po new file mode 100644 index 0000000..61610a7 --- /dev/null +++ b/debian/po/ca.po @@ -0,0 +1,31 @@ +# unattended-upgrades po-debconf translation to Catalan +# Copyright (C) 2007 Software in the Public Interest, SPI Inc. +# This file is distributed under the same license as the PACKAGE package. +# Innocent De Marchi , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.70\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2011-06-01 18:28+0100\n" +"Last-Translator: Innocent De Marchi \n" +"Language-Team: Catalan <>\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=utf-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Poedit-Language: Catalan\n" +"X-Poedit-Country: SPAIN\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Desitjau descarregar i instal·lar automàticament les actualitzacions de la versió estable?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Applying updates on a frequent basis is an important part of keeping systems secure. By default, updates need to be applied manually using package management tools. Alternatively, you can choose to have this system automatically download and install security updates." +msgstr "La instal·lació de les actualitzacions amb freqüència és un aspecte important per a mantenir la seguretat del sistema. Per defecte, les actualitzacions s'han de fer manualment utilitzant les eines de gestió de paquets. Si ho preferiu, podeu optar per fer que el sistema descarregui i instal li automàticament les actualitzacions de seguretat." + diff --git a/debian/po/cs.po b/debian/po/cs.po new file mode 100644 index 0000000..043a28d --- /dev/null +++ b/debian/po/cs.po @@ -0,0 +1,37 @@ +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the unattended-upgrades package. +# Vítězslav Kotrla , 2009. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-05-06 22:11+0200\n" +"PO-Revision-Date: 2009-06-06 22:11+0200\n" +"Last-Translator: Vítězslav Kotrla \n" +"Language-Team: Czech \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: KBabel 1.11.4\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Automaticky stahovat a instalovat aktualizace ze stabilní verze Debianu?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Pravidelné nasazování aktualizací je důležitou součástí udržování zabezpečení " +"systému. Normálně je nutné aktualizace nasazovat ručně za použití příslušných " +"nástrojů pro správu balíčků. Můžete ovšem zvolit, aby tento systém automaticky " +"sám stahoval a instaloval bezpečnostní aktualizace." + diff --git a/debian/po/da.po b/debian/po/da.po new file mode 100644 index 0000000..0826fba --- /dev/null +++ b/debian/po/da.po @@ -0,0 +1,38 @@ +# Danish translation unattended-upgrades. +# Copyright (C) 2011 unattended-upgrades og nedenstående oversættere. +# This file is distributed under the same license as the unattended-upgrades package. +# Joe Hansen (joedalton2@yahoo.dk), 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2011-03-22 19:25+0200\n" +"Last-Translator: Joe Hansen \n" +"Language-Team: Danish \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Hent og installer automatisk stabile opdateringer?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Løbende installation af opdateringer er en vigtig del af at holde et system " +"sikkert. Som standard skal opdateringer installeres manuelt med " +"pakkehåndteringsværktøjer. Alternativt kan du automatisk vælge at lade dette " +"system hente og installere sikkerhedsmæssige opdateringer." + + diff --git a/debian/po/de.po b/debian/po/de.po new file mode 100644 index 0000000..92c6bc4 --- /dev/null +++ b/debian/po/de.po @@ -0,0 +1,134 @@ +# Translation of unattended-upgrades templates to German +# Copyright (C) Helge Kreutzmann , 2009, 2011. +# This file is distributed under the same license as the unattended-upgrades package. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.73.1\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2011-10-30 19:26+0100\n" +"Last-Translator: Helge Kreutzmann \n" +"Language-Team: de \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Aktualisierungen für Stable automatisch herunterladen und installieren?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Das häufige Anwenden von Aktualisierungen ist ein wichtiger Aspekt beim " +"Erhalt der Sicherheit von Systemen. Standardmäßig müssen Aktualisierungen " +"manuell mit den Paketverwaltungswerkzeugen eingespielt werden. Alternativ " +"können Sie wählen, dass das System automatisch die " +"Sicherheitsaktualisierungen herunterlädt und installiert." + +#~ msgid "print debug messages" +#~ msgstr "Debug-Meldungen ausgeben" + +#~ msgid "Initial blacklisted packages: %s" +#~ msgstr "Anfänglich ausgeschlossene Pakete: %s" + +#~ msgid "Starting unattended upgrades script" +#~ msgstr "Unattended-Upgrades-Skript wird gestartet" + +#~ msgid "Allowed origins are: %s" +#~ msgstr "Erlaubte Quellen sind: %s" + +#~ msgid "Cache has broken packages, exiting" +#~ msgstr "" +#~ "Zwischenspeicher (Cache) enthält defekte Pakete, Programm wird beendet" + +#~ msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +#~ msgstr "" +#~ "Upgrade von »%s« möglich, aber Markierung für Upgrade konnte nicht " +#~ "gesetzt werden (%s)" + +#~ msgid "GetArchives() failed: '%s'" +#~ msgstr "GetArchives() fehlgeschlagen: »%s«" + +#~ msgid "An error ocured: '%s'" +#~ msgstr "Ein Fehler ist aufgetreten: »%s«" + +#~ msgid "The URI '%s' failed to download, aborting" +#~ msgstr "" +#~ "Von der URI »%s« konnte nicht heruntergeladen werden, Programm wird " +#~ "beendet" + +#~ msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +#~ msgstr "" +#~ "Paket »%s« enthält eine Conffile-Eingabeaufforderung und das Upgrade muss " +#~ "manuell durchgeführt werden" + +#~ msgid "package '%s' not upgraded" +#~ msgstr "Upgrade von Paket »%s« nicht durchgeführt" + +#~ msgid "No packages found that can be upgraded unattended" +#~ msgstr "" +#~ "Keine Pakete gefunden, von denen ein unbeaufsichtigtes Upgrade " +#~ "durchgeführt werden kann." + +#~ msgid "Packages that are upgraded: %s" +#~ msgstr "Pakete, von denen ein Upgrade durchgeführt wird: %s" + +#~ msgid "Writing dpkg log to '%s'" +#~ msgstr "Dpkg-Protokoll wird nach »%s« geschrieben" + +#~ msgid "pm.GetArchives() failed" +#~ msgstr "pm.GetArchives() fehlgeschlagen" + +#~ msgid "Installing the upgrades failed!" +#~ msgstr "Installation der Upgrades fehlgeschlagen!" + +#~ msgid "error message: '%s'" +#~ msgstr "Fehlermeldung: »%s«" + +#~ msgid "dpkg returned a error! See '%s' for details" +#~ msgstr "Dpkg meldete einen Fehler! Lesen Sie »%s« für Details" + +#~ msgid "All upgrades installed" +#~ msgstr "Alle Upgrades installiert" + +#~ msgid "" +#~ "No '/usr/bin/mail', can not send mail. You probably want to install the " +#~ "'mailx' package." +#~ msgstr "" +#~ "»/usr/bin/mail« nicht vorhanden, es können keine E-Mails versendet " +#~ "werden. Wahrscheinlich müssen Sie das Paket »mailx« installieren." + +#~ msgid "unattended-upgrades result for '%s'" +#~ msgstr "Ergebnis von unattended-upgrades für »%s«" + +#~ msgid "" +#~ "Unattended upgrade returned: %s\n" +#~ "\n" +#~ msgstr "" +#~ "Unbeaufsichtiges Upgrade meldete zurück: %s\n" +#~ "\n" + +#~ msgid "Packages that are upgraded:\n" +#~ msgstr "Pakete, bei denen ein Upgrade durchgeführt wurde:\n" + +#~ msgid "Packages with upgradable origin but kept back:\n" +#~ msgstr "" +#~ "Pakete, bei denen die Quelle Upgrade-fähig war, die aber zurückgehalten " +#~ "wurden:\n" + +#~ msgid "Package installation log:" +#~ msgstr "Paketinstallationsprotokoll:" + +#~ msgid "You need to be root to run this application" +#~ msgstr "Sie müssen »root« sein, um dieses Programm auszuführen." diff --git a/debian/po/es.po b/debian/po/es.po new file mode 100644 index 0000000..75de8de --- /dev/null +++ b/debian/po/es.po @@ -0,0 +1,65 @@ +# unattended-upgrades po-debconf translation to Spanish. +# Copyright (C) 2007 Software in the Public Interest, SPI Inc. +# This file is distributed under the same license as the unattended-upgrades package. +# +# Changes: +# - Initial translation +# Fernando González de Requena , 2009. +# -Reviewers: +# Javier Fernandez-Sanguino +# +# Traductores, si no conoce el formato PO, merece la pena leer la +# documentación de gettext, especialmente las secciones dedicadas a este +# formato, por ejemplo ejecutando: +# info -n '(gettext)PO Files' +# info -n '(gettext)Header Entry' +# +# Equipo de traducción al español, por favor lean antes de traducir +# los siguientes documentos: +# +# - El proyecto de traducción de Debian al español +# http://www.debian.org/intl/spanish/ +# especialmente las notas y normas de traducción en +# http://www.debian.org/intl/spanish/notas +# +# - La guía de traducción de po's de debconf: +# /usr/share/doc/po-debconf/README-trans +# o http://www.debian.org/intl/l10n/po-debconf/README-trans +# +# Si tiene dudas o consultas sobre esta traducción consulte con el último +# traductor (campo Last-Translator) y ponga en copia a la lista de +# traducción de Debian al español () +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.37debian1\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-01-05 10:34+0100\n" +"PO-Revision-Date: 2009-01-06 18:08+0200\n" +"Last-Translator: Fernando González de Requena \n" +"Language-Team: Debian Spanish \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "" +"¿Desea descargar e instalar automáticamente las actualizaciones " +"de la versión estable?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Para mantener el sistema seguro es importante instalar las actualizaciones " +"regularmente. Por omisión, para poder realizar una actualización tiene que utilizar " +"una herramienta de gestión de paquetes. Como alternativa, puede elegir que el " +"sistema descargue e instale automáticamente las actualizaciones de seguridad." diff --git a/debian/po/eu.po b/debian/po/eu.po new file mode 100644 index 0000000..b1d974b --- /dev/null +++ b/debian/po/eu.po @@ -0,0 +1,38 @@ +# translation of eu.po to Euskara +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# +# Piarres Beobide , 2008, 2009. +msgid "" +msgstr "" +"Project-Id-Version: eu\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2009-01-29 01:50+0100\n" +"Last-Translator: Piarres Beobide \n" +"Language-Team: Euskara \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: KBabel 1.11.4\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Bertsio-berritze egonkorrak automatikoki deskargatu eta instalatu?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Maiztasunean oinarritutako bertsio-berritze ezarpenak sistema seguru " +"mantentzearen zati garrantzitsu bat da. Lehenespenez bertsio-berritzeak " +"eskuz pakete kudeaketa elementuak erabiliaz egin behar dira. Bestela " +"segurtasun eguneraketak sistemak automatikoki deskargatu eta instalatzea " +"hautatu dezakezu." diff --git a/debian/po/fi.po b/debian/po/fi.po new file mode 100644 index 0000000..e0786d0 --- /dev/null +++ b/debian/po/fi.po @@ -0,0 +1,40 @@ +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: \n" +"Last-Translator: Esko Arajärvi \n" +"Language-Team: Finnish \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Poedit-Language: Finnish\n" +"X-Poedit-Country: FINLAND\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "" +"Ladataanko ja asennetaanko vakaan jakelun päivitykset automaattisesti? " + +#. Type: boolean +#. Description +#: ../templates:2001 +#, fuzzy +#| msgid "" +#| "Applying updates on a frequent basis is an important part of keeping " +#| "systems secure. By default, updates need to be applied manually using " +#| "package management tools. Alternatively, you can choose to have this " +#| "system automatically download and install security updates." +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Tietoturvan kannalta on tärkeää, että järjestelmää päivitetään " +"säännöllisesti. Oletusarvoisesti päivitykset täytyy asentaa käsin käyttäen " +"pakettienhallintatyökaluja. Tämän ohjelmiston avulla tietoturvapäivitykset " +"voidaan ladata ja asentaa automaattisesti." diff --git a/debian/po/fr.po b/debian/po/fr.po new file mode 100644 index 0000000..254bbd2 --- /dev/null +++ b/debian/po/fr.po @@ -0,0 +1,39 @@ +# unattended-upgrades po-debconf file +# Copyright (C) 2008 +# This file is distributed under the same license as the unattended-upgrades package. +# Michael Vogt , 2008 +# +msgid "" +msgstr "" +"Project-Id-Version: 0.35debian1\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-01-05 10:34+0100\n" +"PO-Revision-Date: 2008-12-03 12:00+0200\n" +"Last-Translator: Steve Petruzzello \n" +"Language-Team: French \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=utf-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "" +"Faut-il automatiquement télécharger et installer les mises à jour de la " +"version stable ?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Il est important de mettre régulièrement son système à jour pour maintenir " +"un haut niveau de sécurité. Par défaut, les mises à jour doivent être " +"appliquées manuellement à l'aide d'un outil de gestion de paquets. À " +"l'inverse, vous pouvez choisir d'automatiser ce processus avec unattended-" +"upgrades." diff --git a/debian/po/it.po b/debian/po/it.po new file mode 100644 index 0000000..f665abe --- /dev/null +++ b/debian/po/it.po @@ -0,0 +1,36 @@ +# Translation of unattended-upgrades debconf templates to Italian +# This file is distributed under the same license as the unattended-upgrades package. +# Luca Monducci , 2008. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.35debian2 debconf\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2008-12-08 18:38+0100\n" +"PO-Revision-Date: 2008-12-08 20:35+0100\n" +"Last-Translator: Luca Monducci \n" +"Language-Team: Italian \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Scaricare e installare automaticamente gli aggiornamenti?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"L'applicazione a cadenza regolare degli aggiornamenti è una parte importante " +"per la sicurezza del proprio sistema. Normalmente gli aggiornamenti devono " +"essere applicati manualmente usando gli strumenti di gestione dei pacchetti; " +"in alternativa è possibile utilizzare questo sistema per scaricare e " +"installare automaticamente gli aggiornamenti di sicurezza." diff --git a/debian/po/ja.po b/debian/po/ja.po new file mode 100644 index 0000000..1cf9b70 --- /dev/null +++ b/debian/po/ja.po @@ -0,0 +1,35 @@ +# Copyright (C) 2008 Michael Vogt +# This file is distributed under the same license as the unattended-upgrades package. +# Hideki Yamane (Debian-JP) , 2008. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.36debian1\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2008-12-21 22:32+0900\n" +"Last-Translator: Hideki Yamane (Debian-JP) \n" +"Language-Team: Japanese \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "自動的に安定版の更新をダウンロードしてインストールしますか?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"更新の適用を頻繁に実施するのは、システムを安全に保つために重要なことです。標" +"準の状態では、更新の適用はパッケージ管理ツールを使って手動で行う必要がありま" +"す。別のやり方として、セキュリティ更新を自動的にダウンロードしてインストール" +"するよう、このシステムを設定するようにもできます。" diff --git a/debian/po/nl.po b/debian/po/nl.po new file mode 100644 index 0000000..b1a56c6 --- /dev/null +++ b/debian/po/nl.po @@ -0,0 +1,38 @@ +# Dutch translation of unattended-upgrades debconf templates. +# Copyright (C) 2011 THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the unattended-upgrades package. +# Jeroen Schot , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades_0.70\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2011-05-09 11:21+0200\n" +"Last-Translator: Jeroen Schot \n" +"Language-Team: Debian l10n Dutch \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Language: nl\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Updates van 'stable' automatisch binnenhalen en installeren?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Regelmatig updates installeren is een belangrijk onderdeel van de " +"beveiliging van systemen. Standaard moeten updates handmatig worden " +"toegepast met een van de hulpprogramma's voor pakketbeheer. U kunt er ook " +"voor kiezen om op dit systeem beveilingingsupdates automatisch binnen te " +"halen en te installeren." diff --git a/debian/po/pt.po b/debian/po/pt.po new file mode 100644 index 0000000..887e1f6 --- /dev/null +++ b/debian/po/pt.po @@ -0,0 +1,38 @@ +# translation of unattended-upgrades debconf to Portuguese +# Copyright (C) 2008 the unattended-upgrades's copyright holder +# This file is distributed under the same license as the unattended-upgrades package. +# +# António Moreira , 2008. +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.35debian2\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2008-12-08 18:38+0100\n" +"PO-Revision-Date: 2008-12-14 11:49+0000\n" +"Last-Translator: António Moreira \n" +"Language-Team: Portuguese \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Transferir e instalar automaticamente actualizações estáveis?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Aplicar actualizações regularmente é uma parte importante para manter os " +"sistemas seguros. Por regra, as actualizações precisam de ser aplicadas " +"manualmente usando ferramentas de gestão de pacotes. Em alternativa, você pode " +"escolher ter este sistema a descarregar e instalar automaticamente as " +"actualizações de segurança." + diff --git a/debian/po/pt_BR.po b/debian/po/pt_BR.po new file mode 100644 index 0000000..b77e19d --- /dev/null +++ b/debian/po/pt_BR.po @@ -0,0 +1,40 @@ +# Debconf translations for unattended-upgrades. +# Copyright (C) 2009 THE unattended-upgrades'S COPYRIGHT HOLDER +# This file is distributed under the same license as the unattended-upgrades package. +# Adriano Rafael Gomes , 2009-2010. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2010-12-17 21:58-0200\n" +"Last-Translator: Adriano Rafael Gomes \n" +"Language-Team: Brazilian Portuguese \n" +"Language: pt_BR\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"pt_BR utf-8\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Baixar e instalar atualizações estáveis automaticamente?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Aplicar atualizações com frequência é uma parte importante de manter os " +"sistemas seguros. Por padrão, as atualizações precisam ser aplicadas " +"manualmente usando ferramentas de gerenciamento de pacotes. " +"Alternativamente, você pode escolher que esse sistema baixe e instale " +"automaticamente as atualizações de segurança." diff --git a/debian/po/ru.po b/debian/po/ru.po new file mode 100644 index 0000000..51bd318 --- /dev/null +++ b/debian/po/ru.po @@ -0,0 +1,41 @@ +# translation of ru.po to Russian +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# +# Yuri Kozlov , 2008. +# Yuri Kozlov , 2009. +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.39debian1\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2009-04-19 10:58+0400\n" +"Last-Translator: Yuri Kozlov \n" +"Language-Team: Russian \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: KBabel 1.11.4\n" +"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%" +"10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "" +"Скачивать и устанавливать обновления стабильного выпуска автоматически?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Регулярная установка обновлений является важной частью обеспечения " +"безопасности системы. По умолчанию, обновления нужно устанавливать вручную с " +"помощью инструментов управления пакетами. Но сейчас можно указать, чтобы " +"обновления безопасности скачивались и устанавливались автоматически." diff --git a/debian/po/sk.po b/debian/po/sk.po new file mode 100644 index 0000000..13b52a5 --- /dev/null +++ b/debian/po/sk.po @@ -0,0 +1,29 @@ +# Slovak translation of unattended-upgrades debconf template. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the udev package. +# Ivan Masár , 2009. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-06-10 21:24+0200\n" +"PO-Revision-Date: 2009-06-13 10:28+0100\n" +"Last-Translator: Ivan Masár \n" +"Language-Team: Slovak \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=utf-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Automaticky sťahovať a inštalovať stabilné aktualizácie?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Applying updates on a frequent basis is an important part of keeping systems secure. By default, updates need to be applied manually using package management tools. Alternatively, you can choose to have this system automatically download and install security updates." +msgstr "Častá aktualizácia je dôležitou súčasťou udrživania zabezpečeného systému. Štandardne je nutné aktualizácie spúšťať ručne pomocou nástrojov na správu balíkov. Namiesto toho môžete nechať tento systém aby za vás autoamticky sťahoval a inštaloval bezpečnostné aktualizácie." + diff --git a/debian/po/sv.po b/debian/po/sv.po new file mode 100644 index 0000000..a428445 --- /dev/null +++ b/debian/po/sv.po @@ -0,0 +1,37 @@ +# translation of unattended-upgrades.po to swedish +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# +# Martin Bagge , 2008. +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: 2008-12-09 16:27+0100\n" +"Last-Translator: Martin Bagge \n" +"Language-Team: swedish \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: KBabel 1.11.4\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "Ska stabila uppdateringar laddas hem och installeras automatiskt?" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" +"Att installera uppdateringar är en viktig del i att hålla systemet säkert. " +"Standardinställningen är att uppdateringar måste installeras manuellt via en " +"pakethanterare. Alternativet är att du kan låta systemet automatiskt ladda " +"hem och installera säkerhetsuppdateringar." diff --git a/debian/po/templates.pot b/debian/po/templates.pot new file mode 100644 index 0000000..6ef9ce8 --- /dev/null +++ b/debian/po/templates.pot @@ -0,0 +1,33 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: unattended-upgrades@packages.debian.org\n" +"POT-Creation-Date: 2009-07-06 17:32+0100\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME \n" +"Language-Team: LANGUAGE \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=CHARSET\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "Automatically download and install stable updates?" +msgstr "" + +#. Type: boolean +#. Description +#: ../templates:2001 +msgid "" +"Applying updates on a frequent basis is an important part of keeping systems " +"secure. By default, updates need to be applied manually using package " +"management tools. Alternatively, you can choose to have this system " +"automatically download and install security updates." +msgstr "" diff --git a/debian/postinst b/debian/postinst new file mode 100644 index 0000000..37c9283 --- /dev/null +++ b/debian/postinst @@ -0,0 +1,66 @@ +#!/bin/sh +# see: dh_installdeb(1) + +set -e + +# Do debconf stuff here +. /usr/share/debconf/confmodule + +# summary of how this script can be called: +# * `configure' +# * `abort-upgrade' +# * `abort-remove' `in-favour' +# +# * `abort-remove' +# * `abort-deconfigure' `in-favour' +# `removing' +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + configure) + # *sigh* typo in filename in version 0.51ubuntu1 + if [ -e /etc/pm/sleep.d/10_unatteded-upgrades-hibernate ]; then + rm -f /etc/pm/sleep.d/10_unatteded-upgrades-hibernate + fi + + db_get unattended-upgrades/enable_auto_updates || true + CONFIG="/etc/apt/apt.conf.d/20auto-upgrades" + if [ "${RET}" = "true" ]; then + NEWFILE="/usr/share/unattended-upgrades/20auto-upgrades" + ucf --three-way --debconf-ok "$NEWFILE" "$CONFIG" + ucfr unattended-upgrades "$CONFIG" + elif [ "${RET}" = "false" ] && [ -e "$CONFIG" ]; then + # disable again + NEWFILE="/usr/share/unattended-upgrades/20auto-upgrades-disabled" + ucf --three-way --debconf-ok "$NEWFILE" "$CONFIG" + ucfr unattended-upgrades "$CONFIG" + fi + + # Recover from incorrect init.d script header in versions < 0.64 + if dpkg --compare-versions "$2" lt "0.64" \ + && [ -f /etc/rc0.d/S[0-9][0-9]unattended-upgrades ] \ + && [ -f /etc/rc6.d/S[0-9][0-9]unattended-upgrades ] ; then + update-rc.d -f unattended-upgrades remove + fi + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + + diff --git a/debian/postrm b/debian/postrm new file mode 100644 index 0000000..9a62029 --- /dev/null +++ b/debian/postrm @@ -0,0 +1,45 @@ +#!/bin/sh +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * `remove' +# * `purge' +# * `upgrade' +# * `failed-upgrade' +# * `abort-install' +# * `abort-install' +# * `abort-upgrade' +# * `disappear' +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + purge) + if [ -x "`which ucf 2>/dev/null`" ]; then + ucf --purge /etc/apt/apt.conf.d/20auto-upgrades + fi + rm -f /etc/apt/apt.conf.d/20auto-upgrades + ;; + + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + + diff --git a/debian/prerm b/debian/prerm new file mode 100644 index 0000000..4fcbff2 --- /dev/null +++ b/debian/prerm @@ -0,0 +1,45 @@ +#!/bin/sh +# prerm script for unattended-upgrades +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * `remove' +# * `upgrade' +# * `failed-upgrade' +# * `remove' `in-favour' +# * `deconfigure' `in-favour' +# `removing' +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + remove|upgrade|deconfigure) + ;; + + failed-upgrade) + if dpkg --compare-versions "$2" lt 0.73.3; then + cat >&2 <&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/debian/pycompat b/debian/pycompat new file mode 100644 index 0000000..d8263ee --- /dev/null +++ b/debian/pycompat @@ -0,0 +1 @@ +2 \ No newline at end of file diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..53dfa90 --- /dev/null +++ b/debian/rules @@ -0,0 +1,28 @@ +#!/usr/bin/make -f + +DIST=$(shell /usr/bin/lsb_release -i -s) + +%: + dh $@ --with python2 + +override_dh_auto_build: + # copy the right template into place + cp data/50unattended-upgrades.$(DIST) data/50unattended-upgrades + dh_auto_build + +override_dh_auto_clean: + # Sanity-check before upload. + set -e; if [ -e /usr/lib/python$(PYVER)/py_compile.py ]; then \ + for f in unattended-upgrade unattended-upgrade-shutdown; do \ + ln -nsf $$f $$f.py; \ + python$(PYVER) /usr/lib/python$(PYVER)/py_compile.py \ + $$f.py; \ + rm -f $$f.py; \ + done; \ + fi + dh_auto_clean + +override_dh_installinit: + # we do not want to run the init script in the postinst/prerm, its + # really only useful on shutdown, see Debian bug #645919 + dh_installinit $@ --no-start -- stop 10 0 6 . diff --git a/debian/templates b/debian/templates new file mode 100644 index 0000000..b6b9bff --- /dev/null +++ b/debian/templates @@ -0,0 +1,17 @@ +# These templates have been reviewed by the debian-l10n-english +# team +# +# If modifications/additions/rewording are needed, please ask +# debian-l10n-english@lists.debian.org for advice. +# +# Even minor modifications require translation updates and such +# changes should be coordinated with translators and reviewers. + +Template: unattended-upgrades/enable_auto_updates +Type: boolean +Default: false +_Description: Automatically download and install stable updates? + Applying updates on a frequent basis is an important part of keeping + systems secure. By default, updates need to be applied manually using package + management tools. Alternatively, you can choose to have this system + automatically download and install security updates. diff --git a/debian/unattended-upgrades.init b/debian/unattended-upgrades.init new file mode 100755 index 0000000..a2623d4 --- /dev/null +++ b/debian/unattended-upgrades.init @@ -0,0 +1,45 @@ +#! /bin/sh +# +### BEGIN INIT INFO +# Required-Start: $local_fs $remote_fs +# Required-Stop: $local_fs $remote_fs +# Provides: unattended-upgrade-shutdown-check +# Default-Start: +# Default-Stop: 0 6 +# Short-Description: Check if unattended upgrades are being applied +# Description: Check if unattended upgrades are being applied +# and wait for them to finish +### END INIT INFO +set -e + +PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin + +NAME="unattended-upgrades" +DESC="unattended package upgrades" +SCRIPTNAME="/etc/init.d/$NAME" +SHUTDOWN_HELPER="/usr/share/unattended-upgrades/unattended-upgrade-shutdown" + +# Load the VERBOSE setting and other rcS variables +. /lib/init/vars.sh + +# Define LSB log_* functions. +# Depend on lsb-base (>= 3.2-14) to ensure that this file is present +. /lib/lsb/init-functions + +case "$1" in +start|restart|force-reload|status) + # nothing, just to keep update-rc.d happy (see debian #630732) + ;; +stop) + if [ -e $SHUTDOWN_HELPER ]; then + [ "$VERBOSE" != "no" ] && log_action_begin_msg "Checking for running $DESC" + python $SHUTDOWN_HELPER + [ "$VERBOSE" != "no" ] && log_action_end_msg $? "$NAME" + fi + ;; +*) + echo "Usage: $SCRIPTNAME {start|stop|status|restart|force-reload}" >&2 + exit 3 + ;; +esac +: diff --git a/man/unattended-upgrade.8 b/man/unattended-upgrade.8 new file mode 100644 index 0000000..8e63a0b --- /dev/null +++ b/man/unattended-upgrade.8 @@ -0,0 +1,57 @@ +.\" Hey, EMACS: -*- nroff -*- +.\" First parameter, NAME, should be all caps +.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection +.\" other parameters are allowed: see man(7), man(1) +.TH unattended-upgrade 8 "May 4, 2009" +.\" Please adjust this date whenever revising the manpage. +.\" +.\" Some roff macros, for reference: +.\" .nh disable hyphenation +.\" .hy enable hyphenation +.\" .ad l left justify +.\" .ad b justify to both left and right margins +.\" .nf disable filling +.\" .fi enable filling +.\" .br insert line break +.\" .sp insert n+1 empty lines +.\" for manpage-specific macros, see man(7) +.SH NAME +unattended-upgrade \- automatic installation of security (and other) upgrades +.SH SYNOPSIS +\fBunattended-upgrade\fP [options] +.br +.SH DESCRIPTION +This program can download and install security upgrades automatically +and unattended, taking care to only install packages from the +configured APT source, and checking for dpkg prompts about +configuration file changes. All output is logged to +/var/log/unattended-upgrades.log. +.sp +This script is the backend for the APT::Periodic::Unattended-Upgrade +option and designed to be run from cron (e.g. via /etc/cron.daily/apt). +.SH OPTIONS +unattended-upgrade accepts the following options: +.TP +\fB-h\fR, \fB\-\-help\fR +help output +.TP +\fB-d\fR, \fB\-\-debug\fR +extra debug output into /var/log/unattended-upgrades.log +.TP +\fB--dry-run\fR +Just simulate installing updates, do not actually do it +.SH CONFIGURATION +The configuration is done via the apt configuration mechanism. The +default configuration file can be found at +/etc/apt/apt.conf.d/50unattended-upgrades +.SH AUTHORS +unattended-upgrade is written by Michael Vogt +.PP +This manual page was originally written by Michael Vogt +.SH COPYRIGHT +Copyright (C) 2005-2009 Canonical +.PP +There is NO warranty. +You may redistribute this software under the terms of the GNU +General Public License. For more information about these matters, see +the files named COPYING. diff --git a/pm/sleep.d/10_unattended-upgrades-hibernate b/pm/sleep.d/10_unattended-upgrades-hibernate new file mode 100755 index 0000000..60f3e64 --- /dev/null +++ b/pm/sleep.d/10_unattended-upgrades-hibernate @@ -0,0 +1,27 @@ +#!/bin/sh + +# Action script ensure that unattended-upgrades is finished +# before a hibernate +# +# Copyright: Copyright (c) 2009 Michael Vogt +# License: GPL-2 +# + +PATH=/sbin:/usr/sbin:/bin:/usr/bin +SHUTDOWN_HELPER=/usr/share/unattended-upgrades/unattended-upgrade-shutdown + +if [ ! -x /usr/share/unattended-upgrades/unattended-upgrade-shutdown ]; then + exit 0 +fi + +case "${1}" in + hibernate) + if [ -e $SHUTDOWN_HELPER ]; then + python $SHUTDOWN_HELPER + fi + ;; + resume|thaw) + # nothing + ;; +esac + diff --git a/po/POTFILES.in b/po/POTFILES.in new file mode 100644 index 0000000..a17393e --- /dev/null +++ b/po/POTFILES.in @@ -0,0 +1,3 @@ +[encoding: UTF-8] +unattended-upgrade +unattended-upgrade-shutdown \ No newline at end of file diff --git a/po/da.po b/po/da.po new file mode 100644 index 0000000..4f564dc --- /dev/null +++ b/po/da.po @@ -0,0 +1,217 @@ +# Danish translation unattended-upgrades. +# Copyright (C) 2012 unattended-upgrades & nedenstående oversættere. +# This file is distributed under the same license as the unattended-upgrades package. +# Joe Hansen , 2012. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-06-16 23:51+0200\n" +"Last-Translator: Joe Hansen \n" +"Language-Team: Danish \n" +"Language: da\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Status: %s %% (%s)" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Alle opgraderinger er installeret" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Installation af opgraderingerne mislykkedes!" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "fejlbesked: »%s«" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "dpkg returnerede en fejl! Se »%s« for detaljer" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Status: %s %%: (%s)" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" +"Ingen »/usr/bin/mail«, kan ikke sende post. Du skal sikkert installere " +"pakken »mailx«." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "[genstart krævet] unattended-upgrades resultat for »%s«" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "unattended-upgrades resultat for »%s«" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"Unattended upgrade returnerede: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Advarsel: En genstart er krævet for at færdiggøre denne opgradering.\n" +"\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Pakker som opgraderes:\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "Pakker med opgraderbar oprindelse men holdt tilbage:\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Log for pakkeinstallation:" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Log for unattended-upgrades:\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Oprindelig sortlistede pakker: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Starter skript for unattended upgrades" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "Tilladte oprindelser er: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "Uklar dpkg-tilstand detekteret, forsøger at rette" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"dpkg --configure -a output:\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "Lås kunne ikke indhentes (kører en anden pakkehåndtering?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "Lås for mellemlager kan ikke indhentes, afslutter" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "Mellemlager har ødelagte pakker, afslutter" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "pakke »%s« kan opgraderes men fejler i markering for opgradering (%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "GetArchives() mislykkedes: »%s«" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Der opstod en fejl: »%s«" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "Der kunne ikke hentes fra adressen »%s«, afbryder" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "Hentning færdig, men filen »%s« var der ikke?!?" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"Pakke »%s« bliver spurgt om oplysninger fra konfigurationsfilen og skal " +"opgraderes manuelt" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "pakke »%s« blev ikke opgraderet" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Pakker som automatisk fjernes: »%s«" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "Ingen pakker fundet som kan opgraderes uden ledsager" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Pakker som blev opgraderet: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Skriver dpkg-log til »%s«" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "vis fejlsøgningsbeskeder" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Simulation, hent men installer ikke" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "Opgrader i små trin (og tillad afbrydelse med SIGINT)" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "Du skal være administrator (root) for at køre dette program" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "Unattended-upgrade i gang under nedlukning, sover for 5 sekunder" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "Opgiver låsefilen efter %s forsinkelse" + diff --git a/po/de.po b/po/de.po new file mode 100644 index 0000000..9424ef8 --- /dev/null +++ b/po/de.po @@ -0,0 +1,227 @@ +# Translation of unattended-upgrades to German. +# Copyright (C) . +# This file is distributed under the same license as the +# unattended-upgrades package. +# Copyright (C) of this file 2012 Chris Leick. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.77\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-06-14 21:28+0200\n" +"Last-Translator: Chris Leick \n" +"Language-Team: German \n" +"Language: de\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Fortschritt: %s %% (%s)" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "alle Upgrades installiert" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Installation der Upgrades fehlgeschlagen!" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "Fehlermeldung: »%s«" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "Dpkg gab einen Fehler zurück. Siehe »%s« für Einzelheiten" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Fortschritt: %s %%: (%s)" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" +"kein »/usr/bin/mail«, Mail kann nicht gesandt werden. Möglicherweise möchten " +"Sie das Paket »mailx« installieren." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "[Neustart erforderlich] Unattended-Upgrades-Ergebnis für »%s«" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "Unattended-Upgrades-Ergebnis für »%s«" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"Das unbeaufsichtigte Upgrade gab %s zurück.\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Warnung: Um dieses Upgrade zu komplettieren, ist ein Neustart erforderlich.\n" +"\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Pakete, von denen ein Upgrade durchgeführt wurde:\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "" +"Pakete, von deren Ursprung ein Upgrade durchgeführt werden kann, die aber\n" +"zurückgehalten werden.\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Paketinstallationsprotokoll:" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Unattended-Upgrades-Protokoll:\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Pakete, die anfangs auf die schwarzen Liste standen: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Skript für unbeaufsichtigte Upgrades wird gestartet." + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "erlaubte Ursprünge sind: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "unsauberer Dpkg-Status entdeckt, es wird versucht dies zu korrigieren" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"»dpkg --configure -a«-Ausgabe:\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "" +"Sperrung konnte nicht erreicht werden (läuft eine weitere Paketverwaltung?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "Zwischenspeicher konnte nicht gesperrt werden, wird beendet" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "Zwischenspeicher enthält beschädigte Pakete, wird beendet" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" +"Von Paket »%s« könnte ein Upgrade durchgeführt werden, es ist jedoch " +"fehlgeschlagen, dies für das Upgrade zu markieren (%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "GetArchives() fehlgeschlagen: »%s«" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Es ist ein Fehler aufgetreten: »%s«" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "Herunterladen von der URI »%s« fehlgeschlagen, wird abgebrochen" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "Herunterladen beendet, aber Datei »%s« ist nicht dort!?" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"Das Paket »%s« hat eine Conffile-Abfrage und muss einem manuellen Upgrade " +"unterzogen werden." + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "Von Paket »%s« wurde kein Upgrade durchgeführt." + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Pakete, die automatisch entfernt wurden: »%s«" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "" +"Es wurden keine Pakete gefunden, von denen ein unbeaufsichtigtes Upgrade " +"durchgeführt werden kann." + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Pakete, von denen ein Upgrade durchgeführt wurde: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Dpkg-Protokoll wird nach »%s« geschrieben" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "Nachrichten zur Fehlersuche ausgeben" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Simulation, herunterladen, aber nicht installieren" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "Upgrade in minimalen Schritten (Unterbrechung mit SIGINT erlaubt)" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "Sie müssen Root sein, um diese Anwendung auszuführen." + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "" +"Unattended-Upgrade läuft während des Herunterfahrens weiter, es wird fünf " +"Sekunden lang gewartet." + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "Sperrdatei, hier wird nach %s Verzögerung aufgegeben." diff --git a/po/es.po b/po/es.po new file mode 100644 index 0000000..7f26d8e --- /dev/null +++ b/po/es.po @@ -0,0 +1,248 @@ +# unattended-upgrades po translation to Spanish +# Copyright (C) 2012 Software in the Public Interest +# This file is distributed under the same license as the unattended-upgrades package. +# +# Changes: +# - Initial translation +# Omar Campagne , 2012 +# +# - Updates +# TRANSLATOR +# +# Traductores, si no conocen el formato PO, merece la pena leer la +# documentación de gettext, especialmente las secciones dedicadas a este +# formato, por ejemplo ejecutando: +# info -n '(gettext)PO Files' +# info -n '(gettext)Header Entry' +# +# Equipo de traducción al español, por favor lean antes de traducir +# los siguientes documentos: +# +# - El proyecto de traducción de Debian al español +# http://www.debian.org/intl/spanish/ +# especialmente las notas y normas de traducción en +# http://www.debian.org/intl/spanish/notas +# +# - La guía de traducción de po's de debconf: +# /usr/share/doc/po-debconf/README-trans +# o http://www.debian.org/intl/l10n/po-debconf/README-trans +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.79\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-07-12 14:04+0200\n" +"Last-Translator: Omar Campagne \n" +"Language-Team: Debian l10n Spanish \n" +"Language: es\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" +"X-Generator: Virtaal 0.7.1\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Progreso: %s %% (%s)" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Se han instalado todas las actualizaciones" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Fallo al instalar actualizaciones" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "Mensaje de fallo: «%s»" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "Se ha detectado un fallo de dpkg. Para más detalles, consulte «%s»" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Progreso: %s %%: (%s)" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" +"No se ha detectado «/usr/bin/mail», no se puede enviar correo. Considere " +"instalar el paquete «mailx»." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "[Se requiere un reinicio] Resultado de unattended-upgrades para «%s»" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "Resultado de unattended-upgrades para «%s»" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"Valor devuelto por unattended-upgrade: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Advertencia: Se requiere reinciar para completar la actualización.\n" +"\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Paquetes que actualizar:\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "" +"Paquetes con una actualización disponible en la fuente pero que no se " +"actualizarán:\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Registro de instalación de paquete:" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Registro de unattended-upgrades:\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Paquetes inicialmente bloqueados: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Iniciando script de unattended-upgrades" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "Fuentes permitidas: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "Se ha detectado un estado no limpio de dpkg, intentando corregir" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"dpkg --configure -a output:\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "" +"No se puede establecer el bloqueo (¿otro gestor de paquetes ejecutándose?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "No se puede establecer el bloqueo de la caché, saliendo" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "La caché tiene paquetes rotos, saliendo" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" +"El paquete «%s» es actualizable, pero no se puede marcar para la " +"actualización (%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "Fallo de GetArchives(): «%s»" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Se ha detectado un fallo: «%s»" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "Fallo al descargar desde el URI «%s», interrumpiendo" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "La descarga ha finalizado, pero no se encuentra el fichero «%s»" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"El paquete «%s» solicita confirmación a través de un conffile, y se debe " +"actualizar de forma manual" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "No se ha actualizado el paquete «%s»" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Paquetes eliminados de forma automática: «%s»" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "No se han encontrado paquetes actualizables sin supervisión" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Paquetes que se han actualizado: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Escribiendo el registro de dpkg en «%s»" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "Mostrar mensajes de depuración de fallos" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Simulacro, descarga pero no instala" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "Actualizar en pequeños pasos (y permitir la interrupción con SIGINT)" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "" +"Necesita tener privilegios de administrador para ejecutar esta aplicación" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "Unattended-upgrade en proceso durante el apagado, esperando 5s" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "Finalizando el bloqueo del fichero después de un retraso de %s" diff --git a/po/eu.po b/po/eu.po new file mode 100644 index 0000000..e350fd4 --- /dev/null +++ b/po/eu.po @@ -0,0 +1,225 @@ +# translation of eu.po to Euskara +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# +# Piarres Beobide , 2008. +msgid "" +msgstr "" +"Project-Id-Version: eu\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2008-12-17 09:28+0100\n" +"Last-Translator: Piarres Beobide \n" +"Language-Team: Euskara \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: KBabel 1.11.4\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Bertsio-berritze guztiak instalatu dira" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Huts bertsio-berritzeak instalatzean!" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "errore mezua: '%s'" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "dpkg-ek errore bat itzuli du! '%s' begiratu xehetasunetarako" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" + +#: ../unattended-upgrade:423 +#, fuzzy, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "" +"Zaindugabeko bertsio-berritze erantzuna: %s\n" +"\n" + +#: ../unattended-upgrade:425 +#, fuzzy, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "" +"Zaindugabeko bertsio-berritze erantzuna: %s\n" +"\n" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"Zaindugabeko bertsio-berritze erantzuna: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" + +#: ../unattended-upgrade:431 +#, fuzzy +msgid "Packages that are upgraded:\n" +msgstr "Bertsio-berritu diren paketeak: %s" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "" + +#: ../unattended-upgrade:442 +#, fuzzy +msgid "Unattended-upgrades log:\n" +msgstr "" +"Zaindugabeko bertsio-berritze erantzuna: %s\n" +"\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Hasierako zerrenda-beltz paketeak: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Zaindugabeko bertsio-berritze script-a abiarazten" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "Onartzen diren jatorriak: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "" + +#: ../unattended-upgrade:548 +#, fuzzy +#| msgid "Cache has broken packages, exiting" +msgid "Cache lock can not be acquired, exiting" +msgstr "Katxeak hondaturiko paketeak ditu, uzten" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "Katxeak hondaturiko paketeak ditu, uzten" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "GetArchives()-ek huts egin du: '%s'" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Errore bat gertatu da: '%s'" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "Huts '%s' URIa deskargatzerakoan, uzten" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"'%s' paketeak konfigurazio galderaren bat du eta eskuz bertsio-berritu behar " +"da" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "'%s' paketea ez da bertsio-berritu" + +#: ../unattended-upgrade:662 +#, fuzzy, c-format +#| msgid "Packages that are upgraded: %s" +msgid "Packages that are auto removed: '%s'" +msgstr "Bertsio-berritu diren paketeak: %s" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "Ez da zaindugabe instalatu daitekeen paketerik aurkitu" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Bertsio-berritu diren paketeak: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Dpkg erregistroa '%s'-en idazten" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "inprimatu arazpen mezuak" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "Root izan behar zara aplikazioa hau exekutatu ahal izateko" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "" + +#~ msgid "pm.GetArchives() failed" +#~ msgstr "pm.GetArchives()-ek huts egin du" diff --git a/po/fr.po b/po/fr.po new file mode 100644 index 0000000..84685d5 --- /dev/null +++ b/po/fr.po @@ -0,0 +1,225 @@ +# Paquet unattended-upgrades +# Copyright (C) 2008 +# This file is distributed under the same license as the unattended-upgrades package. +# Michael Vogt , 2008. +# +msgid "" +msgstr "" +"Project-Id-Version: 0.35\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-05-21 14:40+0200\n" +"Last-Translator: Steve Petruzzello \n" +"Language-Team: French \n" +"Language: fr\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Progression : %s %% (%s)" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Toutes les mises à niveau ont été installées" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Échec de l'installation des mises à niveau" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "Message d'erreur : %s" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "dpkg a renvoyé une erreur. Voir « %s » pour les détails" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Progression : %s %% : (%s)" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" +"L'exécutable « /usr/bin/mail » est introuvable, impossible d'envoyer un " +"courrier électronique. Veuillez installer le paquet « mailx »." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "[Redémarrage requis] unattended-upgrades a renvoyé : %s" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "unattended-upgrades a renvoyé : %s" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"La mise à niveau automatique a renvoyé : %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Avertissement : un redémarrage est requis afin de compléter cette mise à " +"niveau.\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Paquets mis à niveau :\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "" +"Paquets susceptibles d'une mise à niveau mais maintenus dans leur état " +"actuel :\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Journal d'installation du paquet :" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Journal de unattended-upgrades :\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Paquets initialement sur la liste noire : %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Démarrage du script de mise à niveau automatique" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "Les origines permises sont : %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "détection d'un état de dpkg impropre, tentative de correction" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"sortie de « dpkg --configure -a output » :\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "" +"Verrouillage impossible (y a-t-il un autre gestionnaire de paquets en cours " +"d'exécution ?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "Le verrouillage du cache est impossible, abandon" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "Le cache contient des paquets cassés, abandon" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" +"Le paquet « %s » peut être mis à niveau mais échoue à être marqué comme tel " +"(%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "Échec de GetArchives() : %s" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Une erreur s'est produite : %s" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "Échec du téléchargement à l'URI « %s », abandon" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "Téléchargement terminé mais le fichier « %s » est absent !" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"Le paquet « %s » provoque un conflit de fichiers de configuration et " +"nécessite une mise à niveau manuelle" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "Le paquet « %s » n'a pas été mis à niveau" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Suppression automatique des paquets : %s" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "Aucun paquet à mettre à niveau automatiquement" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Paquets mis à niveau : %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Écriture du journal de dpkg dans « %s »" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "Afficher les messages de débogage" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Simulation, télécharge mais n'installe pas" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "" +"Mise à niveau par étapes minimales (et autoriser l'interruption avec SIGINT)" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "" +"Vous devez posséder les privilèges du superutilisateur pour exécuter cette " +"application" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "Unattended-upgrade en cours durant l'extinction, en pause pour 5 s" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "Renonciation sur un fichier verrou après un délai de %s." diff --git a/po/gl.po b/po/gl.po new file mode 100644 index 0000000..ae40850 --- /dev/null +++ b/po/gl.po @@ -0,0 +1,227 @@ +# Galician translations for PACKAGE package. +# Copyright (C) 2012 THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# +# Jorge Barreiro Gonzalez , 2012. +msgid "" +msgstr "" +"Project-Id-Version: \n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-06-23 12:55+0200\n" +"Last-Translator: Jorge Barreiro \n" +"Language-Team: Galician \n" +"Language: gl\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Lokalize 1.0\n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Progreso: %s %% (%s)" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Todas as actualizacións foron instaladas" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Produciuse un erro ao instalar as actualizacións." + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "mensaxe de erro: «%s»" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "«dpkg» devolveu un erro! Consulte «%s» para obter máis detalles." + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Progreso: %s %%: (%s)" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" +"Non existe «/usr/bin/mail», non pode enviar correos. Probablemente " +"queira instalar o paquete «mailx»." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "" +"[precísase reiniciar] resultado da actualización desatendida para «%s»" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "resultado da actualización desatendida para «%s»" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"A actualización desatendida devolveu: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Aviso: Precísase reiniciar para completar esta actualización.\n" +"\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Paquetes que se actualizan:\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "Paquetes co un orixe actualizábel, pero que se manteñen:\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Rexistro de instalación de paquetes:" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Rexistro de «unattended-upgrades»:\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Lista negra de paquetes inicial: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Estase a comezar o script de actualizacións desatendidas" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "Os orixes permitidos son: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "Detectouse un estado «dpkg» sucio, estase a tratar de corrixir" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"Saída de «dpkg --configure -a»:\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "" +"Non se puido bloquear (estase a executar outro xestor de paquetes?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "Non se puido bloquear a caché, sáese" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "A caché contén paquetes rotos, sáese" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" +"O paquete «%s» é actualizábel, pero non foi posíbel marcalo para " +"actualizar (%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "Produciuse un erro en GetArchives(): «%s»" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Produciuse un erro: «%s»" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "Produciuse un erro ao descargar a URI «%s», interrómpese" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "A descarga finalizou, pero o ficheiro «%s» non está aí." + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"O paquete «%s» ten unha petición acerca dos ficheiros de configuración " +"e precisa ser actualizado manualmente" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "O paquete «%s» non foi actualizado" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Paquetes que se eliminan automaticamente: «%s»" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "" +"Non se atoparon paquetes que se poidan actualizar de forma desatendida" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Paquetes que se actualizan: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Escribindo o rexistro «dpkg» a «%s»" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "escribir as menxases de depuración" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Simulación, descargar pero non instalar" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "" +"Actualización en pasos mínimos (e permitir interromper con SIGINT)" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "Precisa reiniciar para executar este aplicativo" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "" +"A actualización desatendida está en progreso durante o apagado, " +"durmindo durante 5s" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "Renunciase ao ficheiro de bloqueo tras un retardo de %s" + diff --git a/po/ja.po b/po/ja.po new file mode 100644 index 0000000..2d318e6 --- /dev/null +++ b/po/ja.po @@ -0,0 +1,222 @@ +# Copyright (C) 2008 Michael Vogt +# This file is distributed under the same license as the unattended-upgrades package. +# Hideki Yamane (Debian-JP) , 2008. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.36debian1\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2008-12-21 22:32+0900\n" +"Last-Translator: Hideki Yamane (Debian-JP) \n" +"Language-Team: Japanese \n" +"Language: ja\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "全てのアップグレードがインストールされました" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "アップグレードのインストールが失敗しました!" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "エラーメッセージ: '%s'" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "dpkg がエラーを返しました! 詳細は '%s' を参照してください" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" + +#: ../unattended-upgrade:423 +#, fuzzy, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "" +"自動アップグレードは以下を返しました: %s\n" +"\n" + +#: ../unattended-upgrade:425 +#, fuzzy, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "" +"自動アップグレードは以下を返しました: %s\n" +"\n" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"自動アップグレードは以下を返しました: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" + +#: ../unattended-upgrade:431 +#, fuzzy +msgid "Packages that are upgraded:\n" +msgstr "アップグレードされたパッケージ: %s" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "" + +#: ../unattended-upgrade:442 +#, fuzzy +msgid "Unattended-upgrades log:\n" +msgstr "" +"自動アップグレードは以下を返しました: %s\n" +"\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "初期状態でブラックリストにあるパッケージ: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "自動アップグレードスクリプトを開始" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "許可されているパッケージ導入元: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "" + +#: ../unattended-upgrade:548 +#, fuzzy +#| msgid "Cache has broken packages, exiting" +msgid "Cache lock can not be acquired, exiting" +msgstr "キャッシュに壊れたパッケージがあるので終了します" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "キャッシュに壊れたパッケージがあるので終了します" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "GetArchives() が失敗しました: '%s'" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "エラー発生: '%s'" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "URI '%s' からダウンロード出来ないので中断します" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"パッケージ '%s' には手動で確認とアップグレードが必要な設定ファイルがあります" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "パッケージ '%s' はアップグレードされませんでした" + +#: ../unattended-upgrade:662 +#, fuzzy, c-format +#| msgid "Packages that are upgraded: %s" +msgid "Packages that are auto removed: '%s'" +msgstr "アップグレードされたパッケージ: %s" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "更新されていないパッケージは見つかりません" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "アップグレードされたパッケージ: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "dpkg のログを '%s' に書き込み中" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "デバッグメッセージを出力" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "このアプリケーションは管理者権限で実行する必要があります" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "" + +#~ msgid "pm.GetArchives() failed" +#~ msgstr "pm.GetArchives() が失敗しました" diff --git a/po/pt.po b/po/pt.po new file mode 100644 index 0000000..46841e9 --- /dev/null +++ b/po/pt.po @@ -0,0 +1,218 @@ +# unattended-upgrades portuguese debconf messages +# Copyright (C) 2012 THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the unattended-upgrades package. +# Pedro Ribeiro , 2012. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-06-24 09:04+0100\n" +"Last-Translator: Pedro Ribeiro \n" +"Language-Team: Portuguese \n" +"Language: pt\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Progresso: %s %% (%s)" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Todas as atualizações instaladas" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Falhou a instalação das atualizações!" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "mensagem de erro: '%s'" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "dpkg retornou um erro! Veja '%s' para mais informação" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Progresso: %s %%: (%s)" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" +"Não existe '/usr/bin/mail', impossível enviar mail. Provavelmente quer " +"instalar o pacote 'mailx'." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "[reinício necessário] resultado do unattended-upgrades para '%s'" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "resultado do unattended-upgrades para '%s'" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"Actualização automática retornou: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Atenção: É necessário reiniciar o computador para completar esta " +"atualização.\n" +"\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Pacotes atualizados:\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "Pacotes com possibilidade de actualização mas mantidos:\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Registo de instalação de pacotes:" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Registo do Unattended-upgrades:\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Lista negra inicial de pacotes: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "A iniciar o script de atualização automática" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "Origens permitidas: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "Detetado estado \"unclean\" de dpkg, a tentar correção" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"dpkg --configure -a output:\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "Não foi possível bloquear (outro gestor de pacotes ativo?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "Não foi possível bloquear cache, a sair" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "A cache tem pacotes corrompidos, a sair" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "o pacote '%s' é atualizável mas não está marcado para atualização (%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "Falhou GetArchives(): '%s'" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Ocorreu um erro: '%s'" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "Falhou o download do URI '%s', a terminar" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "Acabou o download, mas o ficheiro '%s' não existe?!?" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"O pacote '%s' tem uma questão de ficheiro de configuração e necessita de ser " +"atualizado manualmente" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "o pacote '%s' não foi atualizado" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Pacotes automaticamente removidos: '%s'" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "" +"Não foram encontrados pacotes com possibilidade de atualização automatica" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Pacotes atualizados: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "A escrever registo do dpkg para '%s'" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "mostrar mensagens de debug" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Simulação, fazer o download mas não instalar" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "Atualizar em pequenos passos (e permitir interrupções com o SIGINT" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "Necessita de acesso de root para executar esta aplicação" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "Unattended-upgrade em progresso durante o fecho, a dormir por 5s" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "A desistir do ficheiro de lock após um atraso de %s" diff --git a/po/pt_BR.po b/po/pt_BR.po new file mode 100644 index 0000000..bbc799e --- /dev/null +++ b/po/pt_BR.po @@ -0,0 +1,224 @@ +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades-0.61\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-06-14 08:25-0300\n" +"Last-Translator: Sérgio Cipolla \n" +"Language-Team: \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Poedit-Language: Portuguese\n" +"X-Poedit-Country: BRAZIL\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Progresso: %s %% (%s)" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Todas as atualizações instaladas" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "A instalação das atualizações falhou!" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "mensagem de erro: '%s'" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "O dpkg retornou um erro! Veja '%s' para mais detalhes" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Progresso: %s %%: (%s)" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" +"'/usr/bin/mail' não encontrado. Incapaz de enviar email. Você provavelmente " +"gostaria de instalar o pacote 'mailx'." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "" +"[É necessário reiniciar o computador] Resultado da atualização " +"desacompanhada para '%s'" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "Resultado da atualização desacompanhada para '%s'" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"A atualização desacompanhada retornou: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Atenção: é necessário reiniciar o computador para completar esta " +"atualização.\n" +"\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Pacotes atualizados:\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "Pacotes atualizáveis na origem mas mantidos na versão atual:\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Relatório de instalação de pacotes:" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Relatório da atualização desacompanhada:\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Pacotes inicialmente na lista negra: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Iniciando o script da atualização desacompanhada" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "São origens permitidas: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "Tentando corrigir estado não-íntegro no dpkg" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"Saída de dpkg --configure -a:\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "" +"O lock não pôde ser obtido (outro gerenciador de pacotes em funcionamento?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "O lock do cache não pode ser obtido, encerrando" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "O cache tem pacotes quebrados, encerrando" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" +"o pacote '%s' é atualizável mas não é possível marcá-lo para atualização (%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "GetArchives() falhou: '%s'" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Ocorreu um erro; '%s'" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "O URI '%s' falhou no download, abortando" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "Download terminado, mas o arquivo '%s' não está lá?!?" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"O pacote '%s' possui um diálogo conffile e necessita ser atualizado " +"manualmente" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "o pacote '%s' não foi atualizado" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Pacotes autorremovidos: '%s'" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "" +"Não foi encontrado nenhum pacote que possa ser atualizado desacompanhadamente" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Pacotes atualizados: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Escrevendo o relatório do dpkg em '%s'" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "imprimir mensagens de depuração" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Simulação, baixar mas não instalar" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "Atualizar em passos mínimos (e permitir interrupção com SIGINT)" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "Você precisa ser root para executar este aplicativo" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "" +"Atualização desacompanhada em execução durante o encerramento do sistema, " +"atrasando 5s" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "Desistindo do arquivo de lock após %s" + +#~ msgid "pm.GetArchives() failed" +#~ msgstr "pm.GetArchives() falhou" diff --git a/po/ru.po b/po/ru.po new file mode 100644 index 0000000..3c1dc7f --- /dev/null +++ b/po/ru.po @@ -0,0 +1,224 @@ +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the unattended-upgrades package. +# +# Yuri Kozlov , 2010, 2012. +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades 0.77\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-06-21 20:53+0400\n" +"Last-Translator: Yuri Kozlov \n" +"Language-Team: Russian \n" +"Language: ru\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Lokalize 1.2\n" +"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" +"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Ход выполнения: %s %% (%s)" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Все обновления установлены" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Установка обновлений завершилась с ошибкой!" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "сообщение об ошибке: %s" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "dpkg завершилась с ошибкой! Подробности смотрите в %s" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Ход выполнения: %s %%: (%s)" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" +"Нет программы /usr/bin/mail, невозможно послать почту. Вероятно, лучше " +"установить пакет mailx." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "[требуется перезагрузка] Результат unattended-upgrades для «%s»" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "Результат unattended-upgrades для «%s»" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"Результат необслуживаемой установки: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Предупреждение: для завершения обновления требуется перезагрузка.\n" +"\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Обновлённые пакеты:\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "Пакеты, обновлённые в источнике, но оставленные теми же в системе:\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Журнал установки пакетов:" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Журнал unattended-upgrades:\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Пакеты в чёрном списке изначально: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Запускаются сценарии необслуживаемой установки" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "Разрешённые источники: %s" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "Обнаружено состояние незавершённости работы dpkg, попытаемся исправить" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"Результат dpkg --configure -a:\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "Не удалось выполнить блокировку (запущен ещё один менеджер пакетов?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "Не удалось выполнить блокировку кэша, завершение работы" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "В кэше сломанные пакеты, завершение работы" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" +"пакет %s можно обновить, но его не удалось пометить как обновляемый (%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "GetArchives() завершилась с ошибкой: '%s'" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Произошла ошибка: %s" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "Невозможно скачать URI '%s', останов" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "Скачивание завершено, но файла %s нет?!?" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" +"В пакете %s есть conffile с вводом от пользователя и его нужно обновлять " +"вручную" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "пакет %s не обновлён" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Автоматически удаляемые пакеты: «%s»" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "" +"Пакеты, для которых можно выполнить необслуживаемое обновление, не найдены" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Обновлённые пакеты: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Журнал dpkg записывается в %s" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "выводить отладочные сообщения" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Имитация, скачивать но не устанавливать" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "" +"Обновление с минимальным количеством этапов (можно прервать с помощью SIGINT" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "Вы должны быть root для запуска этого приложения" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "Выполнение unattended-upgrade во время выключения, пауза на 5с" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "Отказ по lockfile после %s задержки" + +#~ msgid "pm.GetArchives() failed" +#~ msgstr "pm.GetArchives() завершилась с ошибкой" diff --git a/po/sk.po b/po/sk.po new file mode 100644 index 0000000..caee95a --- /dev/null +++ b/po/sk.po @@ -0,0 +1,220 @@ +# Slovak translation for unattended-upgrades +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the unattended-upgrades package. +# Ivan Masár , 2012. +# +msgid "" +msgstr "" +"Project-Id-Version: unattended-upgrades\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: 2012-06-14 10:05+0100\n" +"Last-Translator: Ivan Masár \n" +"Language-Team: Slovak \n" +"Language: sk\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=3; plural= (n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "Priebeh: %s %% (%s)" + +#: ../unattended-upgrade:190 +#: ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "Všetky aktualizácie sú nainštalované" + +#: ../unattended-upgrade:192 +#: ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "Inštalácia aktualizácií zlyhala!" + +#: ../unattended-upgrade:193 +#: ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "chybová správa: „%s“" + +#: ../unattended-upgrade:194 +#: ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "dpkg vrátil chybu! Podrobnosti nájdete v „%s“" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "Priebeh: %s %%: (%s)" + +#: ../unattended-upgrade:412 +msgid "No '/usr/bin/mail', can not send mail. You probably want to install the 'mailx' package." +msgstr "Chýba „/usr/bin/mail“ nie je možné poslať poštu. Pravdepodobne chcete nainštalovať balík „mailx“." + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "[vyžaduje reštart] výsledok unattended-upgrades pre „%s“" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "výsledok unattended-upgrades pre „%s“" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" +"Bezobslužná aktualizácia vrátila: %s\n" +"\n" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" +"Upozornenie: Na dokončenie tejto aktualizácie sa vyžaduje reštart.\n" +"\n" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "Aktualizavané balíky:\n" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "Aktualizovateľné, ale podržané balíky:\n" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "Záznam inštalácií balíkov:" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "Záznam bezobslužných aktualizácií:\n" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "Prvotná čierna listina balíkov: %s" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "Spúšťa sa skript bezobslužných aktualizácií" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "Povolené pôvody sú: %s" + +#: ../unattended-upgrade:528 +#: ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "Bol zistený nečistý stav dpkg, prebieha pokus o nápravu" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" +"výstup dpkg --configure -a:\n" +"%s" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "Zámok sa nepodarilo získať (beží iný správca balíkov?)" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "Nepodarilo sa získať zámok vyrovnávacej pamäte, program končí" + +#: ../unattended-upgrade:554 +#: ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "Vyrovnávacia pamäť obsahuje poškodené balíky, program končí" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "balík „%s“ je aktualizovateľný, ale nedarí sa označiť na aktualizáciu (%s)" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "GetArchives() zlyhalo: „%s“" + +#: ../unattended-upgrade:610 +#: ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "Vyskytla sa chyba: „%s“" + +#: ../unattended-upgrade:613 +#: ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "URI „%s“ sa nepodarilo stiahnuť, program končí" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "Sťahovanie dokončené, ale súbor „%s“ nie je na mieste?!?" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "Balík „%s“ obsahuje výzvu konfiguračného súboru a musí sa aktualizovať ručne" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "balík „%s“ nebol aktualizovaný" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "Automaticky odstránené balíky: „%s“" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "Neboli nájdené žiadne balíky, ktoré možno aktualizovať bezobslužne" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "Aktualizované balíky: %s" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "Zapisuje sa záznam dpkg do „%s“" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "vypisovať ladiace správy" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "Simulácia - sťahovať, ale neinštalovať" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "Aktualizovať po minimálnych krokoch (a umožniť prerušenie pomocou SIGINT" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "Aby ste mohli spustiť túto aplikáciu, musíte byť root" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "Unattended-upgrade prebieha počas vypínania, čaká sa 5 sekúnd" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "Vzdáva sa pokus o získanie zámku po %s" + diff --git a/po/unattended-upgrades.pot b/po/unattended-upgrades.pot new file mode 100644 index 0000000..6fc8014 --- /dev/null +++ b/po/unattended-upgrades.pot @@ -0,0 +1,207 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-07-19 15:24+0200\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME \n" +"Language-Team: LANGUAGE \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=CHARSET\n" +"Content-Transfer-Encoding: 8bit\n" + +#: ../unattended-upgrade:72 +#, c-format +msgid "Progress: %s %% (%s)" +msgstr "" + +#: ../unattended-upgrade:190 ../unattended-upgrade:254 +msgid "All upgrades installed" +msgstr "" + +#: ../unattended-upgrade:192 ../unattended-upgrade:246 +msgid "Installing the upgrades failed!" +msgstr "" + +#: ../unattended-upgrade:193 ../unattended-upgrade:247 +#, c-format +msgid "error message: '%s'" +msgstr "" + +#: ../unattended-upgrade:194 ../unattended-upgrade:248 +#, c-format +msgid "dpkg returned a error! See '%s' for details" +msgstr "" + +#: ../unattended-upgrade:231 +#, c-format +msgid "Progress: %s %%: (%s)" +msgstr "" + +#: ../unattended-upgrade:412 +msgid "" +"No '/usr/bin/mail', can not send mail. You probably want to install the " +"'mailx' package." +msgstr "" + +#: ../unattended-upgrade:423 +#, c-format +msgid "[reboot required] unattended-upgrades result for '%s'" +msgstr "" + +#: ../unattended-upgrade:425 +#, c-format +msgid "unattended-upgrades result for '%s'" +msgstr "" + +#: ../unattended-upgrade:428 +#, c-format +msgid "" +"Unattended upgrade returned: %s\n" +"\n" +msgstr "" + +#: ../unattended-upgrade:430 +msgid "" +"Warning: A reboot is required to complete this upgrade.\n" +"\n" +msgstr "" + +#: ../unattended-upgrade:431 +msgid "Packages that are upgraded:\n" +msgstr "" + +#: ../unattended-upgrade:435 +msgid "Packages with upgradable origin but kept back:\n" +msgstr "" + +#: ../unattended-upgrade:439 +msgid "Package installation log:" +msgstr "" + +#: ../unattended-upgrade:442 +msgid "Unattended-upgrades log:\n" +msgstr "" + +#: ../unattended-upgrade:513 +#, c-format +msgid "Initial blacklisted packages: %s" +msgstr "" + +#: ../unattended-upgrade:514 +msgid "Starting unattended upgrades script" +msgstr "" + +#: ../unattended-upgrade:517 +#, c-format +msgid "Allowed origins are: %s" +msgstr "" + +#: ../unattended-upgrade:528 ../unattended-upgrade:529 +msgid "Unclean dpkg state detected, trying to correct" +msgstr "" + +#: ../unattended-upgrade:538 +#, c-format +msgid "" +"dpkg --configure -a output:\n" +"%s" +msgstr "" + +#: ../unattended-upgrade:546 +msgid "Lock could not be acquired (another package manager running?)" +msgstr "" + +#: ../unattended-upgrade:548 +msgid "Cache lock can not be acquired, exiting" +msgstr "" + +#: ../unattended-upgrade:554 ../unattended-upgrade:555 +msgid "Cache has broken packages, exiting" +msgstr "" + +#: ../unattended-upgrade:581 +#, c-format +msgid "package '%s' upgradable but fails to be marked for upgrade (%s)" +msgstr "" + +#: ../unattended-upgrade:601 +#, c-format +msgid "GetArchives() failed: '%s'" +msgstr "" + +#: ../unattended-upgrade:610 ../unattended-upgrade:611 +#, c-format +msgid "An error ocured: '%s'" +msgstr "" + +#: ../unattended-upgrade:613 ../unattended-upgrade:614 +#, c-format +msgid "The URI '%s' failed to download, aborting" +msgstr "" + +#: ../unattended-upgrade:617 +#, c-format +msgid "Download finished, but file '%s' not there?!?" +msgstr "" + +#: ../unattended-upgrade:626 +#, c-format +msgid "Package '%s' has conffile prompt and needs to be upgraded manually" +msgstr "" + +#: ../unattended-upgrade:648 +#, c-format +msgid "package '%s' not upgraded" +msgstr "" + +#: ../unattended-upgrade:662 +#, c-format +msgid "Packages that are auto removed: '%s'" +msgstr "" + +#: ../unattended-upgrade:669 +msgid "No packages found that can be upgraded unattended" +msgstr "" + +#: ../unattended-upgrade:679 +#, c-format +msgid "Packages that are upgraded: %s" +msgstr "" + +#: ../unattended-upgrade:693 +#, c-format +msgid "Writing dpkg log to '%s'" +msgstr "" + +#: ../unattended-upgrade:744 +msgid "print debug messages" +msgstr "" + +#: ../unattended-upgrade:747 +msgid "Simulation, download but do not install" +msgstr "" + +#: ../unattended-upgrade:750 +msgid "Upgrade in minimal steps (and allow interrupting with SIGINT" +msgstr "" + +#: ../unattended-upgrade:754 +msgid "You need to be root to run this application" +msgstr "" + +#: ../unattended-upgrade-shutdown:95 +msgid "Unattended-upgrade in progress during shutdown, sleeping for 5s" +msgstr "" + +#: ../unattended-upgrade-shutdown:106 +#, c-format +msgid "Giving up on lockfile after %s delay" +msgstr "" diff --git a/pre-build.sh b/pre-build.sh new file mode 100755 index 0000000..efdce70 --- /dev/null +++ b/pre-build.sh @@ -0,0 +1,6 @@ +#!/bin/sh + +# update po files +for i in po/*.po; do + msgmerge --previous --update $i po/*.pot; +done diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 0000000..78e6d7e --- /dev/null +++ b/setup.cfg @@ -0,0 +1,2 @@ +[build] +i18n=True \ No newline at end of file diff --git a/setup.py b/setup.py new file mode 100755 index 0000000..ace1765 --- /dev/null +++ b/setup.py @@ -0,0 +1,29 @@ +#!/usr/bin/env python + +from distutils.core import setup +from DistUtilsExtra.command import * +import glob +import os + + +setup(name='unattended-upgrades', version='0.1', + scripts=['unattended-upgrade'], + data_files=[ + ('../etc/apt/apt.conf.d/', + ["data/50unattended-upgrades"]), + ('../etc/logrotate.d/', + ["data/logrotate.d/unattended-upgrades"]), + ('../usr/share/unattended-upgrades/', + ["data/20auto-upgrades", + "data/20auto-upgrades-disabled", + "unattended-upgrade-shutdown"]), + ('../usr/share/man/man8/', + ["man/unattended-upgrade.8"]), + ('../etc/pm/sleep.d/', + ["pm/sleep.d/10_unattended-upgrades-hibernate"]) + ], + cmdclass = { "build" : build_extra.build_extra, + "build_i18n" : build_i18n.build_i18n } + ) + + diff --git a/test/Makefile b/test/Makefile new file mode 100644 index 0000000..53d4451 --- /dev/null +++ b/test/Makefile @@ -0,0 +1,19 @@ +#!/usr/bin/make + +all: check + +check: + set -e; \ + find . -name 'test_*.py' | \ + while read file; do \ + echo "Running $$file"; \ + if [ -x $$file ]; then \ + python $$file ; \ + fi \ + done + +clean: + rm -rf ./aptroot/var/cache/ + rm -rf ./aptroot/var/lib/apt + rm -rf ./aptroot/var/run + diff --git a/test/aptroot/etc/apt/apt.conf.d/50unattended-upgrades b/test/aptroot/etc/apt/apt.conf.d/50unattended-upgrades new file mode 100644 index 0000000..340daa2 --- /dev/null +++ b/test/aptroot/etc/apt/apt.conf.d/50unattended-upgrades @@ -0,0 +1,36 @@ +// Automatically upgrade packages from these (origin, archive) pairs +Unattended-Upgrade::Allowed-Origins { + "Ubuntu lucid-security"; +}; + +// List of packages to not update +Unattended-Upgrade::Package-Blacklist { +// "vim"; +// "libc6"; +// "libc6-dev"; +// "libc6-i686"; + "ant-doc"; +}; + +// Send email to this address for problems or packages upgrades +// If empty or unset then no email is sent, make sure that you +// have a working mail setup on your system. The package 'mailx' +// must be installed or anything that provides /usr/bin/mail. +//Unattended-Upgrade::Mail "root@localhost"; + +// Set this value to "true" to get emails only on errors. Default +// is to always send a mail if Unattended-Upgrade::Mail is set +//Unattended-Upgrade::MailOnlyOnError "true"; + +// Do automatic removal of new unused dependencies after the upgrade +// (equivalent to apt-get autoremove) +//Unattended-Upgrade::Remove-Unused-Dependencies "false"; + +// Automatically reboot *WITHOUT CONFIRMATION* if a +// the file /var/run/reboot-required is found after the upgrade +//Unattended-Upgrade::Automatic-Reboot "false"; + + +// Use apt bandwidth limit feature, this example limits the download +// speed to 70kb/sec +//Acquire::http::Dl-Limit "70"; diff --git a/test/aptroot/etc/apt/sources.list b/test/aptroot/etc/apt/sources.list new file mode 100644 index 0000000..f7887d5 --- /dev/null +++ b/test/aptroot/etc/apt/sources.list @@ -0,0 +1,4 @@ +# updates +deb http://archive.ubuntu.com/ubuntu/ lucid-updates main restricted +# security +deb http://security.ubuntu.com/ubuntu lucid-security main restricted diff --git a/test/aptroot/etc/apt/trusted.gpg b/test/aptroot/etc/apt/trusted.gpg new file mode 100644 index 0000000000000000000000000000000000000000..eac2524abd9932c6e5fbe85f789a6b2fa78ce0be GIT binary patch literal 3502 zcmZYBXIRrq76;%zNob)3gLEV`=_(*adIte%B2791f`%Hn(uuTSE`%y5C6Ve( zu+Sk@6{k=1+I-$K_szY}g(9U#QtcdbUqK5}HmpY;xAnO)zt2*V9*dJtI9uWm-06fzt!w*~5q%sF$>=vJ`?u6K^5C^wMlkiYPRT>;@b5 z5?Mb5aLvh-;$(nOW2Izw2_)M7$Udx}_=EBGqzJ|i0+dg3IldZE4t*TY8?xT4#@^8_K{cCaiiqw1FTgav59cNpc{n=}a19x7Yw5 z*4JyMtYP=bO-owFb$A!%q`9N>U^&w;u*UaNOeut@!tm88AxA4o;NvdEZVv5ylTFsK zYAye$9Reim3P>K5;AWBUM7dwPO~R$E2i)tP@tI22+jsW4Vv=#jdE|+DBPB)=AnJ-? zS)w}UDijJ4Hx1<>RWvC>hmhGr^s=J${BW`|_h|>Y5j-zs#$QaO{UZ2P?=M?k+&Z&!Z$k5GS9C_*RL^R{o87eXf#6@YX{ z`FbL*`}+9%`uiYEy}}Xd-l#yNdkD%aSUdFZ^%pz?keV152%H@RoTCL%-x4Y^Hxtu1YH7D7p^@ z;PTJBmg^Uq20dzVYP&V`P_ojLbe^KKuz7`UO*1|f+Wo?dur0XV5m2r!q#}Jh%NH0o zjubNoU6o`|MGqjJKpinPEphd&EsEwk9FB0lE{=&rvgw4I?TfxghbsEj`hRVO%4T?E zlz1+V@{`eT%e4}jUKvY7?BvGhHN5Sm3E|S$wu}tCzGZX5_@&l-CF>Z+TIIPO95J>i zcu;P~!{aR~+V6(ncS#b<$103pvjgVl`=;npUbAu8GYaj#14aC4duYf6lUCF~CcpmL z_SjPdx5ZnJY;NMv=;U`5TQc!wV2j`1$rD*@Wc6m z-xd@K**$oDEzhcY7U57GjnM}|ZXE7ye(^gfY{>JgNA`jw*}SW3uHluQNS&SU^!%%K zTqjyYnUBw&h;Eoic3@E0#!p2}(~zC+FqZ@I^A08L!AmEd^iDRn#>;54X3&Y{$#n{= z67tb$vC3b|V2>yf?fw9N5mOYkg5#Ju-`r4-4*AlmBV5ZLt)0Z%@3UC|KAaWsJ_kHJT;Q zkz!T7ZDZGQzKgho`!(V3^JU_@8fChV?GbN$ZCAcA`!9GkT3Yi{cWRQ_@M%NmQ4_L}R3Yj`87c;s1BCRe#n_p=%{OYF9Q;0{9bQyXc9RG2VTRwt+7WB^ zf4*72T6`8i!vB#Q{hLKGU7}hmJAQE#75ex0ZUA`O3bFeIne>XZMuNDheUr!K)1!I- zUV9-nb4&YW#GSM$&6{^*@$OU0ng6u(Mj|^&b03q$8 z^E$}h|JWWeoE(V=karn>{0<4@GwA@Ga796-n(+8-Hn^v5lI&MPo4d??Ht zjez~1rAxJ#t}wWbR(SJpW&s6^91`FL?GT~O`>+*L(8L@h9a{txiK`sM#;Nn!x|_z@ z|4dPnrK6dD@_&{a)w)pqFulxjJ)u|_Ak2-4HV>g5AyzsnFgZN7Dj&*Ow*h?U)-;De zuWTz;LNKVI{%~Rte>vwj%V#c%YUM1`*Tk4Q<=R96MRH$*wYc~BOGEs{`zNzA>rzGX zrhp>lVX?}^WUXh>t_YXqBE=Ge!n@GlECP)r)p9_$P9&Rd4NE}*e5@pz1i4GsdXCd* z(6&u}Q+T~|_B3_ohKZL-_J>!P0+d(aypMT86dc zLaIfcR{+6&n7xTA0`R&#g=UvSxrzB?uelJ-3a9r$oEtzPOnGJHUnO*sdo- zar0z=(1>*B%^$DCVjD{ukCet2MJj8w{%t*vYaE8qjovif4ZE} z<-r^(#zaYo)e^sWlcO325bJYU)?&4z@}k{IwRtfBvGWs8e$HX-9$T-zhK8NU^5Y2h zW)UMFWFXFqsm zj24=%+{+hlg~comNzyxHync|vo)mW1H(Jg!hQl4Qi8g}n+gQ?oZ8aAPL_&XHAM~%{ z?@J0#^5X3M1kIn5`6#mcJmd>7w_>;WmawB`h&4y#@Z~Rstlbg1igvtgF%D8>Ori?{ z)uH2+R`w_2!F&XB%^7r*7h>R5M!zpBmN%>BC$kH&m*b0VJY8^?IeWW}2y*bshukBM zEqfu*BO_VAj{)V+fN6)tn_9(DHri_gl8?-)s*?{jNmsx_ zejWv0lkVJARuhN3sH#8i4q9p8+zqvcSFh^&$`9RyfISv3~3F$}gRBMx@6f$?FflEgV0s(EJ13b(U0G+q4STm1Xt~ zbNXA1KelbTCw)!Z$Vt%nwSG|7otIfBWSxkT4--5ulp5ro1+*D*PAWWO zo{^XWsiZM<&y$4~f2u76uBGI9**-D5rLMR|EATF%ueS5HPFhuva#fSUbUMO&n5?{u z&AT>=_uEC4Q6tg{Vxf-HMlc3oSgcdfbj!?YE3ZY{UvyS-)0-#5s&wC!pEY~#f#aO0 zb-~9y-%4<-a_gC~y@2cCJC0lp36~7G;_Pv|;oB1?8xkI?fh~PMf)p}OLjBUP!ClUd zo$50UYY)Gc&CZ*I11qJ$K#DArxmv>6)ZpUb7MMhuUraT+Z_c*(#$AJRLgkFA=cClD zSYpVx zzqPpH3nP;5;0Lb zQ~RCA+_r&B!wTuP8KfhqI}H&2;&GcR<$`=rJnFwbYii9aOaDw9-p^8B5MOb-v9anK z=D2k(W1KnIHtR;CS4&G#xd}UmIb@Jhc`{x&HY(8)9+y~yeC2bZhLRuDr4g?lI;)_o zuY=aWbZdO^=n|{E43eG~S;}RdFms$@h5AHJIhU^8TnM#yry1OoxoF3{1xKD7B$#pN z`7Nph4^12!)#2pl|Jq$SMhPfugh+I320BNpz8V(fqltKsBmEgJuuvp?7a`LwAP^~mi=^wvHP nOZQ{mVwC=K1%PnBRK8?e(SkXGxp;sQF|hW>5f|z-Uf_QNy%PIE literal 0 HcmV?d00001 diff --git a/test/aptroot/var/lib/dpkg/lock b/test/aptroot/var/lib/dpkg/lock new file mode 100644 index 0000000..e69de29 diff --git a/test/aptroot/var/lib/dpkg/status b/test/aptroot/var/lib/dpkg/status new file mode 100644 index 0000000..3ee35b9 --- /dev/null +++ b/test/aptroot/var/lib/dpkg/status @@ -0,0 +1,52 @@ +Package: awstats +Status: install ok installed +Priority: extra +Section: admin +Installed-Size: 1260 +Maintainer: Ubuntu Core Developers +Architecture: all +Version: 6.9~dfsg-1ubuntu3 +Description: dummy + +Package: perl +Status: install ok installed +Priority: standard +Section: perl +Installed-Size: 18556 +Maintainer: Ubuntu Developers +Architecture: amd64 +Version: 5.10.1-17ubuntu1 +Description: Larry Wall's Practical Extraction and Report Language + An interpreted scripting language, known among some as "Unix's Swiss + Army Chainsaw". + . + Perl is optimised for scanning arbitrary text files and system + administration. It has built-in extended regular expression matching + and replacement, a data-flow mechanism to improve security with + setuid scripts and is extensible via modules that can interface to C + libraries. + +Package: ant-doc +Status: install ok installed +Priority: optional +Section: doc +Installed-Size: 35776 +Maintainer: Ubuntu Core Developers +Architecture: all +Version: 1.0 +Description: Java based build tool like make - API documentation and manual + A system independent (i.e. not shell based) build tool that uses XML files + as "Makefiles". This package contains the manual of ant as well as the + Javadoc API documentation. + +Package: apt-doc +Status: install ok installed +Priority: optional +Section: doc +Installed-Size: 388 +Maintainer: Ubuntu Developers +Architecture: all +Version: 0.7.25.3ubuntu9 +Description-en_GB: Documentation for APT + This package contains the user guide and offline guide, for APT, an + Advanced Package Tool. diff --git a/test/aptroot/var/log/apt/history.log b/test/aptroot/var/log/apt/history.log new file mode 100644 index 0000000..67685a0 --- /dev/null +++ b/test/aptroot/var/log/apt/history.log @@ -0,0 +1,4 @@ + +Start-Date: 2012-08-07 12:20:17 +Upgrade: awstats:amd64 (6.9~dfsg-1ubuntu3, 6.9~dfsg-1ubuntu3.10.04.1), apt-doc:amd64 (0.7.25.3ubuntu9, 0.7.25.3ubuntu9.13) +End-Date: 2012-08-07 12:20:17 diff --git a/test/aptroot/var/log/apt/term.log b/test/aptroot/var/log/apt/term.log new file mode 100644 index 0000000..3b94366 --- /dev/null +++ b/test/aptroot/var/log/apt/term.log @@ -0,0 +1,3 @@ + +Log started: 2012-08-07 12:20:17 +Log ended: 2012-08-07 12:20:17 diff --git a/test/aptroot/var/log/unattended-upgrades.log b/test/aptroot/var/log/unattended-upgrades.log new file mode 100644 index 0000000..d925e21 --- /dev/null +++ b/test/aptroot/var/log/unattended-upgrades.log @@ -0,0 +1,25 @@ +2012-08-07 12:20:12,876 INFO Initial blacklisted packages: ant-doc +2012-08-07 12:20:12,877 INFO Starting unattended upgrades script +2012-08-07 12:20:12,877 INFO Allowed origins are: ['o=Ubuntu,a=lucid-security'] +2012-08-07 12:20:13,973 DEBUG Checking: ant-doc (["", ""]) +2012-08-07 12:20:13,975 DEBUG skipping blacklisted package 'ant-doc' +2012-08-07 12:20:13,976 DEBUG Checking: apt-doc (["", ""]) +2012-08-07 12:20:14,020 DEBUG Checking: awstats (["", ""]) +2012-08-07 12:20:14,105 DEBUG pkgs that look like they should be upgraded: apt-doc +awstats +2012-08-07 12:20:17,510 DEBUG fetch.run() result: 0 +2012-08-07 12:20:17,511 DEBUG +2012-08-07 12:20:17,515 DEBUG check_conffile_prompt('/home/egon/devel/unattended-upgrades/build-area/unattended-upgrades-0.79.3/test/aptroot/var/cache/apt/archives/apt-doc_0.7.25.3ubuntu9.13_all.deb') +2012-08-07 12:20:17,520 DEBUG found pkg: apt-doc +2012-08-07 12:20:17,522 DEBUG No conffiles in deb '/home/egon/devel/unattended-upgrades/build-area/unattended-upgrades-0.79.3/test/aptroot/var/cache/apt/archives/apt-doc_0.7.25.3ubuntu9.13_all.deb' (There is no member named 'conffiles') +2012-08-07 12:20:17,525 DEBUG +2012-08-07 12:20:17,528 DEBUG check_conffile_prompt('/home/egon/devel/unattended-upgrades/build-area/unattended-upgrades-0.79.3/test/aptroot/var/cache/apt/archives/awstats_6.9~dfsg-1ubuntu3.10.04.1_all.deb') +2012-08-07 12:20:17,532 DEBUG found pkg: awstats +2012-08-07 12:20:17,535 DEBUG blacklist: ['ant-doc'] +2012-08-07 12:20:17,587 DEBUG Checking (blacklist): apt-doc +2012-08-07 12:20:17,628 DEBUG Checking (blacklist): awstats +2012-08-07 12:20:17,669 DEBUG InstCount=2 DelCount=0 BrokenCout=0 +2012-08-07 12:20:17,676 INFO Option --dry-run given, *not* performing real actions +2012-08-07 12:20:17,677 INFO Packages that are upgraded: apt-doc awstats +2012-08-07 12:20:17,678 INFO Writing dpkg log to '/home/egon/devel/unattended-upgrades/build-area/unattended-upgrades-0.79.3/test/aptroot/var/log/unattended-upgrades-dpkg_2012-08-07_12:20:17.678406.log' +2012-08-07 12:20:17,984 INFO All upgrades installed diff --git a/test/create_debug_lock.py b/test/create_debug_lock.py new file mode 100644 index 0000000..468512f --- /dev/null +++ b/test/create_debug_lock.py @@ -0,0 +1,14 @@ +#!/usr/bin/python +# +# create a lock file so that unattended-upgrades-shutdown pauses +# on shutdown -- useful for testing + +import apt_pkg +import os +import time + +pid = os.fork() +if pid == 0: + os.setsid() + lock = apt_pkg.get_lock("/var/run/unattended-upgrades.lock") + time.sleep(500) diff --git a/test/data/50unattended-upgrades.Test b/test/data/50unattended-upgrades.Test new file mode 100644 index 0000000..258a9bf --- /dev/null +++ b/test/data/50unattended-upgrades.Test @@ -0,0 +1,6 @@ +// Automatically upgrade packages from these (origin, archive) pairs +Unattended-Upgrade::Origins-Pattern { + "o=aOrigin,a=aArchive"; + "s=aSite,l=aLabel"; + "o=Google\, Inc.,suite=stable"; +}; diff --git a/test/data/50unattended-upgrades.compat b/test/data/50unattended-upgrades.compat new file mode 100644 index 0000000..4201c27 --- /dev/null +++ b/test/data/50unattended-upgrades.compat @@ -0,0 +1,6 @@ +// Automatically upgrade packages from these (origin:archive) pairs +Unattended-Upgrade::Allowed-Origins { + "Google, Inc.:stable"; + "MoreCorp\, eink:stable"; + "${distro_id}:${distro_codename}-security"; +}; diff --git a/test/data/listchanges.conf.mail b/test/data/listchanges.conf.mail new file mode 100644 index 0000000..8b598c0 --- /dev/null +++ b/test/data/listchanges.conf.mail @@ -0,0 +1,6 @@ +[apt] +frontend=mail +email_address=root +confirm=0 +save_seen=/var/lib/apt/listchanges.db +which=both diff --git a/test/data/listchanges.conf.pager b/test/data/listchanges.conf.pager new file mode 100644 index 0000000..df97c6b --- /dev/null +++ b/test/data/listchanges.conf.pager @@ -0,0 +1,6 @@ +[apt] +frontend=pager +email_address=root +confirm=0 +save_seen=/var/lib/apt/listchanges.db +which=both diff --git a/test/mock-mail b/test/mock-mail new file mode 100755 index 0000000..ee632f5 --- /dev/null +++ b/test/mock-mail @@ -0,0 +1,4 @@ +#!/bin/sh + +echo $2 > mail.txt +cat - -- >> mail.txt diff --git a/test/mock-sendmail b/test/mock-sendmail new file mode 100755 index 0000000..1d5d6a4 --- /dev/null +++ b/test/mock-sendmail @@ -0,0 +1,3 @@ +#!/bin/sh + +cat - -- > mail.txt diff --git a/test/packages/conf-test-package-257-conffiles_1.deb b/test/packages/conf-test-package-257-conffiles_1.deb new file mode 100644 index 0000000000000000000000000000000000000000..011197a430acc7693d0db9fbdafd57dfd55934b5 GIT binary patch literal 1542 zcmai!do&XY9LE=VY?T>0^R`gOqsF|pHJR(3D^YPpXy!GIX?9t3@BIGw{eI{7JHPWeWR4@_gDpV*0e%Er z*fBps7>;}e27@7t4UG(uC?pC2gBkATUp>Om(9FaH2HVvay9hFZ8-nnpFbbJOgi~;2 zcu@5B>k$Y9`g4PeAdM7hz<(wtzBqJ=cs4+_Rlo?{@6NTelp}GBfO5}|B#5eCd6ddl84viPY=h>t~YZbjU{S;0rI9<2tm6kJJ z7d!cZSGppWY1P#3PGe72Wvo2dxm!AoKE1hwRxejt-f%!Ev=d9i+t$|?Em;BdcwEki zhBQM7{F57#gb~rM7F9gjR^lfBX;EP@8dVl2+ zY|nlQ7xeGzoy$FVYQpmc1ySth;Wl&Z#m{A#sJ`xtmQ|CJ;&$lLEt<0tL}h%7oiHNm zP~ET85k$9&`<>pojiuf3T^EtlCDIcI9WuNZBNuL;oqp;e{bJZv}NBw+=*^ zU?LMToR{kzjuy=8=akWUa=-xUnICy%+P2i`Ydg=Dr4lT>MRjd*zHj)RQLp9O7FfuF zppc-&{l0Nm^r>^A#~G+C=GKTgkfbnDSwRTX{OkpCrmhg-QgX zdGQN7cYw)l%6tewyuimJ8uYRt0G2wDwkeL-2>K2JAQ#q z(6J_EB1Xow8WO96?X{-zK^d+rtw${jEoLRHj(oaTxM@MI!ifo%P!jVVl-+oSpUAxz z$3#V@Ax6gV4QbW28m@c*wwuBE;VuGGDe;>}TxWt)O8DUdKhankZf8DcI~v5 zh33j)(@du#h|gE3(ouepGD``^a0&}?wL(p$0;D^TFWK*!HtdIA%iWh%q1;iS7%|Gx zR@DgY+(W?|59W#=^GFIg*GTtGW(k!s6_7tK8~i#N?STTbp~@>KES~eIl4`*%V%HH$ z`2zWfxBD6xP=U0Z1Q$JUmy_M8x)AGoQ0SQ}sKS)h6@%P@ZTpi8KyF1=`VJN)!9hgx zevw82iRV2qA_DVAunr`)yjL$%syAK*ArH-0WX#U9o42Sy{dAiXfn!Eajfl<7?U|Oq z5^E{X3fY%MmcX<=-V!I0*r@l=<%Y78Jvw@Je*K$83d^yvVGYc}O4ZaNTUlrx0NeX& zsp)U33|KQU%OzD;F(qerNRt#*>4qlL>+%7(tk8=DC&nj_)Y0_~TpV9o5poCVHAvgNZ#Kj|A#8>f zZ1!E3w!zEG&(qn#WgWeOKkgTte(MKrC#8S zM$R1RJl*3pFKK6GwR|(Ip9r=_o5j@dO+puk`Bdp??9nn!wNi literal 0 HcmV?d00001 diff --git a/test/packages/conf-test-package-new-conffile_1.deb b/test/packages/conf-test-package-new-conffile_1.deb new file mode 100644 index 0000000000000000000000000000000000000000..651655be020b858a02605e4775cd32d65915b7f7 GIT binary patch literal 640 zcmY$iNi0gvu;WTeP0CEn(@o0EODw8XP*5;5HZia?urxF_P*4COAb^mD1_ov(CJG8b z1O*9PMtTNZ$@zIDMfo{;C5c6P=~aaF8yTCz^~-m2Fn|CP^V_St`I-zw*dCm-agAqq z!RRGye*eJ9y_sA>oHK$Rz2=r!#P^8h*pK?tp81z|nsnWKb;Lo_(k&>+=D4JCkk(Qa z(X2b+m3k7>bC_$NZ+$%H=BC_f?`p072L|TcTBfn;R@v%j_UAW!|LOm7V!hNm!IM1_ z;wS#UN_u@Zgeml<_1o3kIFBbyU~H~8_`1J5ckib^@vrKIPQL!5?v>K?@BSgj*_-v= z_Eq2h`JpJjwRdmZ=ludQYhSnR-0)bWGvWQ2m7lKtxX0UH5}OrlxyyU4%iM-R zgMoo7C9xzC9!S6tAQa9ENnE1_G@Q*VK0HYj~S7%i?_SRxgL36{Usu{~hBN zj|~+M6ZoHRY;f{j%j8{!-IEU`?eWVGeD~b``QFIap=X_L-ad9D^y1!wPi;z*LwEkO zc(Sv)|D1iu-8a8;Uwx{YU1a`GXWD(=YOKa#C|G1Tc__vNTCzWCL7zcROf zkpFP~|F@9;+b>PqJAHxM|NZ*^?@r))hL(nK{qo%$3?RV7{Pv=6*C7Xiwue#AMQRz7 z!zXz)@7{TEO`5#Z;v|nHm+#dZ@ia-7iUwB5Yjpj(S^G3B?78^CH|w(v>Tj=ixjO5? z>RYd}Znj@*vY0Hsu3Ia-L_Bw>_!;z z{(<dQZ+B97`R=TW{)@*JovSWu1^%qst04GwV(zW)nf7fDPH3Ec zutEOxL5Wq{Ys=s7cYkiLrT=Q9R@w{s`LFULTO)4V?)dll>-t}Lmvi`?EzN4T-!aL3 zd+&~Y#eb*z`C&#q|KeZ&fA^FBpL=+iXVSr-~M&o&Dme3K6}PD<0YTY rrkty@7wX;qHY1&--sJzc?DzKb@7K5gWQPR~n65a=Y15+j7#uRth_tgJ^$z3<~Kk8Tl}wN57LSG~e9w_6>{XYLA|ZR~n~_tIPUW}Yuy zx@P0Kt?bd$jJAm^-V$7Hkp9s#d+K48qQ`gqf4_FU_RIZ>?+m@=mko~X$@~{v{=@G7 zH|77e+x36y%X>+Gx*sE~8Z-Yu!Mw@S6L-Ctc054y5BK$d(@lD%&;OtO_x?`(&--BS1_MJ%Vo4%Ah=AcoD3lE?&EcVp6iSy2xta|m93GyTr^KFN+Ub^maizGxMKc99 z6TZE*r2@B{ZZGX>{Vw>UJ;gKbk;@uC->yUFg2lsZ&$V9gik_WzD?@q8wQCuQYi}H| zXxTJ9h-WJQ!^1oCf1h@p_EY`Q628z)i~niO{Usfo^5y=z`lq{(#U9(obFTdOv8`X% z|9)QiZQp)V{lA}ovMycp|JAv0^Anj(TgXk@zZmwyOkM{0-!;57jtlU K>M>9NZ~*{jH1lNu literal 0 HcmV?d00001 diff --git a/test/packages/conf-test-package_1.1.deb b/test/packages/conf-test-package_1.1.deb new file mode 100644 index 0000000000000000000000000000000000000000..6d0d8a51602221f75563a9d78c928ac0db86e5b1 GIT binary patch literal 618 zcmY$iNi0gvu;WTeP0CEn(@o0EODw8XP*5;5G%zwTHZ(LfRZuVh@?oT*fq|KciGl(U zK|unSk)8opa(-S(QGSkINn(*+dKF>)M#hG4{qo%$3}C?g_KG9lAq4@}fNQp_;u})C zE*zO_Uhs6Dz^dL}Q-i(x*Dkv_W5sHz-v7C5Owylbp5!*PHeI1*9JZ=w*Lq>cuAYnD zo2IoW8O>@jdBptdh@O|`r1vx8?^KuD*`}Yh&%s$KU^?pKJNV zUauwOM17fSLj6ysv+Mf%X207ZVehQ=KtJZ!{N(HBZ2rf8+i%MMIexO)i~s&NEb0q( zZ9nu(SWL?e%REd=Q_&$@@=vssdiJGiWd{aHS-c zB*Fs-=zBt8Y-kA!TE8m4IHL1NF;sO`L1Xz2!@9o5Oi$QM%l7uTH_|k6hM7q`J%zT{`#HL6cue7ovJo-~Vkd zzyI!f|C-PKErCx@zp(gwS!MR`+Yvl}zrT+E7JD~l*}@OL_vgM|wzlrBz3=4jfA41h xFNtGZ%KO)Rdi?Cb^UE*zTQ8U{Yr*Px@AsnI{KN%tzXKTs9_4GgCRTyG4*++><%R$N literal 0 HcmV?d00001 diff --git a/test/packages/multiple-conffiles_1_all.deb b/test/packages/multiple-conffiles_1_all.deb new file mode 100644 index 0000000000000000000000000000000000000000..76d2b2032ef67ee127fbeb02eb47eaa1872ddab1 GIT binary patch literal 660 zcmY$iNi0gvu;WTeP0CEn(@o0EODw8XP*5;5HZU)M#g4v{qo%$3?RV7{PybEzC#KE>;>m)x#A8? zTgWPuzpqjKeM^FB_u7SD{<;d6eqS&ztIYiW{ZyvIxpph0w^;;AEY+LXBXs{UuX2#r zc9+=fQ+qG&N{!jbKVx~0@bfd@AAfjtclRIpQ1d*QZ@&fpZprvtdfj&Y{%QTcyidAV zmdq+_{H4F{Wy2KM=>v^KbB^u!@UPzT|FXY3|937q_NV^H zwO#tRf1BE$Gi(q3vif&@z}uQxr|zt`yt?R?N;${P-8RcV-8$Cc3ib_x_z*pZ@ux?c z4TA;)LrP*vB0P|QAwVdcjf{=3h0_(^u0sYA$3Cv9?vgo>`FWdX6?b@XFK`fZSP@!oh1!RIxqNxi<$xB8#o8mt|$ zY^UVbu!ja;`tSWM`@igy(wW^!t$$wce;R+YMDJLb)4$hG_e=jWlbg12=Hm)M#g4v{qo%$3?RV7{PwCX-ysDV)`DmAnz+9( zM=88~#yjT@=RvO{*8-~QS9bPxTWt;eT<7e`ef#m>=qV|sp^I8(gfDaXy2no7Sj&Xc zs%tj2;XxWstTzvsxXEg$Zj=61{@m{E{}qc&oa=3@@{fmpp6>hEs{Z8kKhpC)`Rn(p zY;pRxT07U|yY_=!nlE0o+0EByJ{_0yq36KB`xx76TF12Wx7(elx6nmL)Vl(Jb~XcZZww1~wDD zXK$t1z3MY^#kGu|*03-=dw0%u*~}Yrd%V_8pY5${e=nb9^R;COVL?aVFYSE1tJ_OD8|v@X z-`n*+ZSDW}|Nk#KvHoxRm;Vp`ZO@x?==<0DPbRlkz1PpMgNGJ~abRr~YidgLA5e$^ E0QF-LC;$Ke literal 0 HcmV?d00001 diff --git a/test/root.conffile/etc/configuration-file b/test/root.conffile/etc/configuration-file new file mode 100644 index 0000000..e880f30 --- /dev/null +++ b/test/root.conffile/etc/configuration-file @@ -0,0 +1,3 @@ +This is a configuration file, +dfasddfasdff +No really. diff --git a/test/root.conffile/etc/configuration-file1 b/test/root.conffile/etc/configuration-file1 new file mode 100644 index 0000000..95d30c6 --- /dev/null +++ b/test/root.conffile/etc/configuration-file1 @@ -0,0 +1,3 @@ +This is a first configuration file, + +No really. diff --git a/test/root.conffile/etc/configuration-file2 b/test/root.conffile/etc/configuration-file2 new file mode 100644 index 0000000..6546a41 --- /dev/null +++ b/test/root.conffile/etc/configuration-file2 @@ -0,0 +1,3 @@ +This is a second configuration file, + +It is modified by the user. by the user. diff --git a/test/root.conffile/etc/configuration-file5 b/test/root.conffile/etc/configuration-file5 new file mode 100644 index 0000000..224fd23 --- /dev/null +++ b/test/root.conffile/etc/configuration-file5 @@ -0,0 +1 @@ +lala diff --git a/test/root.conffile/var/lib/dpkg/status b/test/root.conffile/var/lib/dpkg/status new file mode 100644 index 0000000..4eeb316 --- /dev/null +++ b/test/root.conffile/var/lib/dpkg/status @@ -0,0 +1,22 @@ +Package: test-package +Status: install ok installed +Architecture: all +Version: 0.9 +Conffiles: + /etc/not-available-config-file 99b99d59ac8f5ecd3375107755ee8599 + /etc/configuration-file 26b99d59ac8f5ecd3375107755ee8527 + /etc/not-available-config-file2 88b99d59ac8f5ecd3375107755ee8588 + /etc/configuration-file2 404d877bbd67dc2412ba80d7c92d6bc7 + +Package: multiple-conffiles +Status: install ok installed +Architecture: all +Version: 1.0 +Conffiles: + /etc/configuration-file1 cb9a458f0fdc96e10b4d23923f16e3a0 + /etc/configuration-file2 8bf10a884dcfe6a8c3e57039e14d2b92 + +Package: test-package-new-conffile +Status: install ok installed +Architecture: all +Version: 0.9 diff --git a/test/test_against_real_archive.py b/test/test_against_real_archive.py new file mode 100755 index 0000000..99f7d99 --- /dev/null +++ b/test/test_against_real_archive.py @@ -0,0 +1,62 @@ +#!/usr/bin/python + +import apt +import apt_pkg +import glob +import os +import re +import unittest + +import unattended_upgrade + +apt_pkg.config.set("APT::Architecture", "amd64") + +class MockOptions(): + def __init__(self, debug=True, dry_run=True): + self.debug = debug + self.dry_run = dry_run + self.minimal_upgrade_steps = False + +class TestAgainstRealArchive(unittest.TestCase): + + def setUp(self): + for f in glob.glob("./aptroot/var/log/*"): + if os.path.isfile(f): + os.remove(f) + + def test_against_real_archive(self): + # get a lucid based cache (test good for 5y) + cache = apt.Cache(rootdir="./aptroot") + cache.update() + del cache + # create mock options + options = MockOptions(debug=True) + # ensure apt does not do any post-invoke stuff that fails + # (because we are not root) + apt_pkg.config.clear("DPkg::Post-Invoke") + # run unattended-upgrades against fake system + logdir = os.path.abspath("./aptroot/var/log/") + logfile = os.path.join(logdir, "unattended-upgrades.log") + apt_pkg.config.set("APT::UnattendedUpgrades::LogDir", logdir) + unattended_upgrade.DISTRO_CODENAME = "lucid" + res = unattended_upgrade.main(options, os.path.abspath("./aptroot")) + # check if the log file exists + self.assertTrue(os.path.exists(logfile)) + log = open(logfile).read() + # check that stuff worked + self.assertFalse(" ERROR " in log) + # check if we actually have the expected ugprade in it + self.assertTrue( + re.search("INFO Packages that are upgraded:.*awstats", log)) + # apt-doc has a higher version in -updates than in -security + # and no other dependencies so its a perfect test + self.assertTrue( + re.search("INFO Packages that are upgraded:.*apt-doc", log)) + self.assertFalse( + re.search("INFO Packages that are upgraded:.*ant-doc", log)) + self.assertTrue( + re.search("DEBUG skipping blacklisted package 'ant-doc'", log)) + +if __name__ == "__main__": + unittest.main() + diff --git a/test/test_conffile.py b/test/test_conffile.py new file mode 100755 index 0000000..dc0c40b --- /dev/null +++ b/test/test_conffile.py @@ -0,0 +1,60 @@ +#!/usr/bin/python + +import apt_pkg +import logging +import unittest +import sys + +from unattended_upgrade import conffile_prompt + +class ConffilePromptTestCase(unittest.TestCase): + + def setUp(self): + apt_pkg.config.set("Dir::State::status", + "./root.conffile/var/lib/dpkg/status") + + def test_will_prompt(self): + # conf-test 0.9 is installed, 1.1 gets installed + # they both have different config files + test_pkg = "./packages/conf-test-package_1.1.deb" + self.assertTrue(conffile_prompt(test_pkg, prefix="./root.conffile"), + "conffile prompt detection incorrect") + + def test_will_not_prompt(self): + # conf-test 0.9 is installed, 1.0 gets installed + # they both have the same config files + test_pkg = "./packages/conf-test-package_1.0.deb" + self.assertFalse(conffile_prompt(test_pkg, prefix="./root.conffile"), + "conffile prompt detection incorrect") + + def test_with_many_entries(self): + # ensure we don't crash when encountering a conffile with overly + # many entries + test_pkg = "./packages/conf-test-package-257-conffiles_1.deb" + self.assertFalse(conffile_prompt(test_pkg, prefix="./root.conffile"), + "conffile prompt detection incorrect") + + def test_will_not_prompt_because_of_conffile_removal(self): + # no conffiles anymore in the pkg + test_pkg = "./packages/conf-test-package-no-conffiles-anymore_2.deb" + self.assertFalse(conffile_prompt(test_pkg, prefix="./root.conffile"), + "conffile prompt detection incorrect") + + def test_will_prompt_multiple(self): + # multiple conffiles + test_pkg = "./packages/multiple-conffiles_2_all.deb" + self.assertTrue(conffile_prompt(test_pkg, prefix="./root.conffile"), + "conffile prompt detection incorrect") + + def test_will_prompt_for_new_conffile(self): + # debian bug #673237, a package that was not a conffile now + # becomes a conffile + test_pkg = "./packages/conf-test-package-new-conffile_1.deb" + self.assertTrue(conffile_prompt(test_pkg, prefix="./root.conffile"), + "conffile prompt detection incorrect") + + +if __name__ == "__main__": + logging.basicConfig(level=logging.DEBUG) + unittest.main() + diff --git a/test/test_in_chroot.py b/test/test_in_chroot.py new file mode 100644 index 0000000..8c5836d --- /dev/null +++ b/test/test_in_chroot.py @@ -0,0 +1,207 @@ +#!/usr/bin/python + +import apt +import logging +import glob +import os +import re +import shutil +import subprocess +import sys +import time +import unittest + +# debian +#SOURCES_LIST=""" +#deb http://ftp.de.debian.org/debian squeeze main contrib non-free +#deb http://ftp.de.debian.org/debian squeeze-updates main contrib non-free +#deb http://ftp.de.debian.org/debian squeeze-proposed-updates main contrib non-f#ree +#deb http://security.debian.org squeeze/updates main contrib non-free +#""" +#DISTRO="squeeze" +#ARCH="i386" +#TARBALL="%s-%s.tgz" % (DISTRO, ARCH) +#MIRROR="http://ftp.de.debian.org/debian" +#APT_CONF="""APT::Architecture "%s";""" % ARCH +#ORIGINS_PATTERN="origin=Debian,archive=stable,label=Debian-Security" + + +# ubuntu +SOURCES_LIST=""" +deb http://archive.ubuntu.com/ubuntu/ lucid main restricted +deb-src http://archive.ubuntu.com/ubuntu/ lucid main restricted + +deb http://archive.ubuntu.com/ubuntu/ lucid-updates main restricted +deb-src http://archive.ubuntu.com/ubuntu/ lucid-updates main restricted + +deb http://security.ubuntu.com/ubuntu/ lucid-security main restricted +deb-src http://security.ubuntu.com/ubuntu/ lucid-security main restricted +""" +DISTRO="lucid" +ARCH="i386" +TARBALL="%s-%s.tgz" % (DISTRO, ARCH) +MIRROR="http://archive.ubuntu.com/ubuntu" +APT_CONF="""APT::Architecture "%s";""" % ARCH +ORIGINS_PATTERN="origin=Ubuntu,archive=lucid-security" + +apt.apt_pkg.config.set("APT::Architecture", ARCH) +sys.path.insert(0, "..") +import unattended_upgrade + +class MockOptions(object): + debug = True + dry_run = False + minimal_upgrade_steps = False + +class TestUnattendedUpgrade(unittest.TestCase): + + def _create_new_debootstrap_tarball(self, tarball, target): + print "creating initial test tarball, this is needed only once" + # force i386 + subprocess.call(["debootstrap", + "--arch=%s" % ARCH, + # smaller version of the minimal system + "--variant=minbase", + "--include=python-apt,apt-utils,gpgv,ubuntu-keyring,ca-certificates", + DISTRO, + target, + MIRROR]) + subprocess.call(["chroot", target, "apt-get", "clean"]) + subprocess.call(["tar", "czf", tarball, target]) + + def _unpack_debootstrap_tarball(self, tarball, target): + subprocess.call(["tar", "xzf", tarball]) + + def test_normal_upgrade(self): + print "Running normal unattended upgrade in chroot" + options = MockOptions() + options.minimal_upgrade_steps = False + # run it + target = self._run_upgrade_test_in_real_chroot(options) + # ensure we upgraded the expected packages + self.assertTrue(self._verify_install_log_in_real_chroot(target)) + + def test_minimal_steps_upgrade(self): + print "Running minimal steps unattended upgrade in chroot" + options = MockOptions() + options.minimal_upgrade_steps = True + # run it + target = self._run_upgrade_test_in_real_chroot(options) + # ensure we upgraded the expected packages + self.assertTrue(self._verify_install_log_in_real_chroot(target)) + + def test_upgrade_on_shutdown_upgrade(self): + print "Running unattended upgrade on shutdown (download and install) in chroot" + # ensure that it actually installs in shutdown env mode + options = MockOptions() + os.environ["UNATTENDED_UPGRADES_FORCE_INSTALL_ON_SHUTDOWN"] = "1" + apt.apt_pkg.config.set("Unattended-Upgrade::InstallOnShutdown", "1") + target = self._run_upgrade_test_in_real_chroot(options) + self.assertTrue(self._verify_install_log_in_real_chroot(target)) + + def _get_lockfile_location(self, target): + return os.path.join( + target, "var/log/unattended-upgrades/unattended-upgrades.log") + + def _setup_chroot(self, target): + """ helper that setups a clean chroot """ + if os.path.exists(target): + shutil.rmtree(target) + if not os.path.exists(TARBALL): + self._create_new_debootstrap_tarball(TARBALL, target) + # create new + self._unpack_debootstrap_tarball(TARBALL, target) + open(os.path.join(target, "etc/apt/apt.conf"), "w").write(APT_CONF) + open(os.path.join(target, "etc/apt/sources.list"), "w").write( + SOURCES_LIST) + + + def _run_upgrade_test_in_real_chroot(self, options, clean_chroot=True): + """ helper that runs the unattended-upgrade in a chroot + and does some basic verifications + """ + if os.getuid() != 0: + print "Skipping because uid != 0" + return + + # clear to avoid pollution in the chroot + apt.apt_pkg.config.clear("Acquire::http::ProxyAutoDetect") + + # create chroot + target = "./test-chroot.%s" % DISTRO + + # setup chroot if needed + if clean_chroot: + self._setup_chroot(target) + + # and run the upgrade test + pid = os.fork() + if pid == 0: + # chroot + os.chroot(target) + os.chdir("/") + if not os.path.exists("/var/log/unattended-upgrades/"): + os.makedirs("/var/log/unattended-upgrades/") + # make sure we are up-to-date + subprocess.call(["apt-get","update", "-q", "-q"]) + # run it + apt.apt_pkg.config.clear("Unattended-Upgrade::Allowed-Origins") + apt.apt_pkg.config.clear("Unattended-Upgrade::Origins-Pattern") + apt.apt_pkg.config.set( + "Unattended-Upgrade::Origins-Pattern::", ORIGINS_PATTERN) + unattended_upgrade.DISTRO_CODENAME = "lucid" + unattended_upgrade.main(options) + os._exit(0) + else: + has_progress=False + all_progress = "" + last_progress = "" + progress_log = os.path.join( + target, "var/run/unattended-upgrades.progress") + while True: + time.sleep(0.01) + if os.path.exists(progress_log): + progress = open(progress_log).read() + if progress and progress != last_progress: + has_progress = progress.startswith("Progress") + last_progress = progress + all_progress += progress + # check exit status + (apid, status) = os.waitpid(pid, os.WNOHANG) + if pid == apid: + ret = os.WEXITSTATUS(status) + break + #print "*******************", all_progress + self.assertEqual(ret, 0) + # this number is a bit random, we just want to be sure we have + # progress data + self.assertTrue(has_progress, True) + self.assertTrue(len(all_progress) > 5) + return target + + def _verify_install_log_in_real_chroot(self, target): + # examine log + log = self._get_lockfile_location(target) + logfile = open(log).read() + #print logfile + NEEDLE_PKG="ca-certificates" + if not re.search( + "Packages that are upgraded:.*%s" % NEEDLE_PKG, logfile): + logging.warn("Can not find expected %s upgrade in log" % NEEDLE_PKG) + return False + if "ERROR Installing the upgrades failed" in logfile: + logging.warn("Got a ERROR in the logfile") + return False + dpkg_log = os.path.join( + target, "var/log/unattended-upgrades/*-dpkg*.log") + dpkg_logfile = open(glob.glob(dpkg_log)[0]).read() + if not "Preparing to replace %s" % NEEDLE_PKG in dpkg_logfile: + logging.warn("Did not find %s upgrade in the dpkg.log" % NEEDLE_PKG) + return False + #print dpkg_logfile + return True + + +if __name__ == "__main__": + #logging.basicConfig(level=logging.DEBUG) + unittest.main() diff --git a/test/test_logdir.py b/test/test_logdir.py new file mode 100755 index 0000000..7ec53d8 --- /dev/null +++ b/test/test_logdir.py @@ -0,0 +1,48 @@ +#!/usr/bin/python + +import apt_pkg +import logging +import os +import mock +import sys +import tempfile +import unittest + +sys.path.insert(0, "..") +from unattended_upgrade import _setup_logging + +class MockOptions: + dry_run = False + debug = False + +class TestLogdir(unittest.TestCase): + + def setUp(self): + self.tempdir = tempfile.mkdtemp() + apt_pkg.init() + self.mock_options = MockOptions() + + def test_logdir(self): + # test log + logdir = os.path.join(self.tempdir, "mylog") + apt_pkg.config.set("Unattended-Upgrade::LogDir", logdir) + logging.root.handlers = [] + _setup_logging(self.mock_options) + self.assertTrue(os.path.exists(logdir)) + + def test_logdir_depreated(self): + # test if the deprecated APT::UnattendedUpgrades dir is not used + # if the new UnaUnattendedUpgrades::LogDir is given + logdir = os.path.join(self.tempdir, "mylog-use") + logdir2 = os.path.join(self.tempdir, "mylog-dontuse") + apt_pkg.config.set("Unattended-Upgrade::LogDir", logdir) + apt_pkg.config.set("APT::UnattendedUpgrades::LogDir", logdir2) + logging.root.handlers = [] + _setup_logging(self.mock_options) + self.assertTrue(os.path.exists(logdir)) + self.assertFalse(os.path.exists(logdir2)) + + +if __name__ == "__main__": + logging.basicConfig(level=logging.DEBUG) + unittest.main() diff --git a/test/test_mail.py b/test/test_mail.py new file mode 100755 index 0000000..ad3747b --- /dev/null +++ b/test/test_mail.py @@ -0,0 +1,135 @@ +#!/usr/bin/python +# -*- coding: utf-8 -*- +import apt_pkg +import os +import unittest + +from email.parser import Parser +from StringIO import StringIO + +import unattended_upgrade +from unattended_upgrade import send_summary_mail, setup_apt_listchanges + + +# note this is not a unittest.TestCase as it needs to be parameterized +class CommonTestsForMailxAndSendmail(object): + + EXPECTED_MAIL_CONTENT_STRINGS = [ + "logfile_dpkg text", + "mem_log text", + "Packages that are upgraded:\n 2vcard", + ] + + def common_setup(self): + # monkey patch to make it testable + unattended_upgrade.REBOOT_REQUIRED_FILE = "./reboot-required" + unattended_upgrade.MAIL_BINARY = "./no-mailx-binary-here" + unattended_upgrade.SENDMAIL_BINARY = "./no-sendmail-binary-here" + # setup mail + apt_pkg.config.set("Unattended-Upgrade::Mail", "root") + apt_pkg.config.set("Unattended-Upgrade::MailOnlyOnError", "false") + + def tearDown(self): + for f in ["mail.txt", "reboot-required", "apt-term.log"]: + if os.path.exists(f): + os.unlink(f) + + def _return_mock_data(self, successful=True): + """ return input tuple for send_summary_mail """ + pkgs = "\n".join(["2vcard"]) + res = successful + pkgs_kept_back = [] + # include some unicode chars here for good measure + mem_log = StringIO(u"mem_log text üöä") + logfile_dpkg = "./apt-term.log" + open("./apt-term.log", "w").write("logfile_dpkg text") + return (pkgs, res, pkgs_kept_back, mem_log, logfile_dpkg) + + def _verify_common_mail_content(self, mail_txt): + for expected_string in self.EXPECTED_MAIL_CONTENT_STRINGS: + self.assertTrue(expected_string in mail_txt) + + def test_summary_mail_reboot(self): + open("./reboot-required","w").write("") + send_summary_mail(*self._return_mock_data()) + os.unlink("./reboot-required") + mail_txt = open("mail.txt").read() + self.assertTrue("[reboot required]" in mail_txt) + self._verify_common_mail_content(mail_txt) + + def test_summary_mail_no_reboot(self): + send_summary_mail(*self._return_mock_data()) + mail_txt = open("mail.txt").read() + self.assertFalse("[reboot required]" in mail_txt) + self._verify_common_mail_content(mail_txt) + + def test_summary_mail_only_on_error(self): + # default is to always send mail, ensure this is correct + # for both success and failure + apt_pkg.config.set("Unattended-Upgrade::MailOnlyOnError", "false") + send_summary_mail(*self._return_mock_data(successful=True)) + self._verify_common_mail_content(open("mail.txt").read()) + os.remove("mail.txt") + # now with a simulated failure + send_summary_mail(*self._return_mock_data(successful=False)) + self._verify_common_mail_content(open("mail.txt").read()) + os.remove("mail.txt") + # now test with "MailOnlyOnError" + apt_pkg.config.set("Unattended-Upgrade::MailOnlyOnError", "true") + send_summary_mail(*self._return_mock_data(successful=True)) + self.assertFalse(os.path.exists("mail.txt")) + send_summary_mail(*self._return_mock_data(successful=False)) + mail_txt = open("mail.txt").read() + self._verify_common_mail_content(mail_txt) + self.assertTrue("Unattended upgrade returned: False" in mail_txt) + self.assertTrue(os.path.exists("mail.txt")) + + def test_apt_listchanges(self): + # test with sendmail available + unattended_upgrade.SENDMAIL_BINARY="/bin/true" + setup_apt_listchanges("./data/listchanges.conf.mail") + self.assertEqual(os.environ["APT_LISTCHANGES_FRONTEND"], "mail") + # test without sendmail + unattended_upgrade.SENDMAIL_BINARY="/bin/not-here-xxxxxxxxx" + setup_apt_listchanges("./data/listchanges.conf.pager") + self.assertEqual(os.environ["APT_LISTCHANGES_FRONTEND"], "none") + + +class MailxTestCase(CommonTestsForMailxAndSendmail, unittest.TestCase): + + def setUp(self): + self.common_setup() + unattended_upgrade.MAIL_BINARY = "./mock-mail" + + def _verify_common_mail_content(self, mail_txt): + CommonTestsForMailxAndSendmail._verify_common_mail_content( + self, mail_txt) + # setting this header with mailx is not possible so ensure + # we don't accidently try + self.assertFalse('text/plain; charset="utf-8"' in mail_txt) + +class SendmailTestCase(CommonTestsForMailxAndSendmail, unittest.TestCase): + + def setUp(self): + self.common_setup() + unattended_upgrade.SENDMAIL_BINARY = "./mock-sendmail" + + def _verify_common_mail_content(self, mail_txt): + CommonTestsForMailxAndSendmail._verify_common_mail_content( + self, mail_txt) + msg = Parser().parsestr(mail_txt) + content_type = msg["Content-Type"] + self.assertEqual(content_type, 'text/plain; charset="utf-8"') + + +class SendmailAndMailxTestCase(SendmailTestCase): + + def setUp(self): + self.common_setup() + unattended_upgrade.MAIL_BINARY = "./mock-mail" + unattended_upgrade.SENDMAIL_BINARY = "./mock-sendmail" + +if __name__ == "__main__": + #logging.basicConfig(level=logging.DEBUG) + unittest.main() + diff --git a/test/test_minimal_partitions.py b/test/test_minimal_partitions.py new file mode 100755 index 0000000..136a044 --- /dev/null +++ b/test/test_minimal_partitions.py @@ -0,0 +1,57 @@ +#!/usr/bin/python + +import apt +import apt_pkg +import os +import logging +import unittest +import sys +import time + +import unattended_upgrade + +class LogInstallProgressMock(unattended_upgrade.LogInstallProgress): + + # klass data so that we can veriy in the test as the actual + # object is destroyed + DATA = [] + + # overwrite to log the data + def status_change(self, pkg, percent, status): + print pkg, percent + self.DATA.append([pkg, percent]) + +class TestMinimalPartitions(unittest.TestCase): + + def setUp(self): + # setup dry-run mode for apt + apt_pkg.config.set("Dir::Cache", "/tmp") + apt_pkg.config.set("Debug::NoLocking","1") + apt_pkg.config.set("Debug::pkgDPkgPM","1") + apt_pkg.config.set("Dir::State::extended_states", "./extended_states") + apt_pkg.config.clear("Dpkg::Post-Invoke") + apt_pkg.config.clear("Dpkg::Pre-Install-Pkgs") + self.cache = apt.Cache() + + def tearDown(self): + if os.path.exists("./extended_states"): + os.remove("./extended_states") + + def test_upgrade_in_minimal_steps(self): + self.cache.upgrade(True) + pkgs_to_upgrade = [pkg.name for pkg in self.cache.get_changes()] + unattended_upgrade.PROGRESS_LOG="./aptroot/var/run/unatteded-upgrades.progress" + unattended_upgrade.LogInstallProgress = LogInstallProgressMock + unattended_upgrade.upgrade_in_minimal_steps( + self.cache, pkgs_to_upgrade) + # ensure we count upwarts + last_percent = -1 + for (pkg, percent) in LogInstallProgressMock.DATA: + self.assertTrue(last_percent < percent) + last_percent = percent + # cleanup class data + LogInstallProgressMock.DATA = [] + +if __name__ == "__main__": + #logging.basicConfig(level=logging.DEBUG) + unittest.main() diff --git a/test/test_origin_pattern.py b/test/test_origin_pattern.py new file mode 100755 index 0000000..5ce5cdb --- /dev/null +++ b/test/test_origin_pattern.py @@ -0,0 +1,121 @@ +#!/usr/bin/python + +import apt +import apt_pkg +import os +import logging +import unittest +import sys + +import unattended_upgrade +from unattended_upgrade import ( + match_whitelist_string, check_changes_for_sanity, is_allowed_origin) + +class MockOrigin(): + pass +class MockCandidate(): + pass +class MockPackage(): + pass +class MockCache(list): + pass +class MockDepCache(): + pass + +class TestOriginPatern(unittest.TestCase): + + def setUp(self): + pass + def tearDown(self): + pass + def test_match_whitelist_string(self): + origin = self._get_mock_origin( + "OriginUbuntu", "LabelUbuntu", "ArchiveUbuntu", + "archive.ubuntu.com", "main") + # good + s="o=OriginUbuntu" + self.assertTrue(match_whitelist_string(s, origin)) + s="o=OriginUbuntu,l=LabelUbuntu,a=ArchiveUbuntu,site=archive.ubuntu.com" + self.assertTrue(match_whitelist_string(s, origin)) + # bad + s="" + self.assertFalse(match_whitelist_string(s, origin)) + s="o=something" + self.assertFalse(match_whitelist_string(s, origin)) + s="o=LabelUbuntu,a=no-match" + self.assertFalse(match_whitelist_string(s, origin)) + # with escaping + origin = self._get_mock_origin("Google, Inc.", archive="stable") + # good + s="o=Google\, Inc.,a=stable" + self.assertTrue(match_whitelist_string(s, origin)) + + def test_match_whitelist_from_conffile(self): + # read some + apt_pkg.config.clear("Unattended-Upgrade") + apt_pkg.read_config_file(apt_pkg.config, "./data/50unattended-upgrades.Test") + allowed_origins = unattended_upgrade.get_allowed_origins() + #print allowed_origins + self.assertTrue("o=aOrigin,a=aArchive" in allowed_origins) + self.assertTrue("s=aSite,l=aLabel" in allowed_origins) + self.assertTrue("o=Google\, Inc.,suite=stable" in allowed_origins) + + def test_compatiblity(self): + apt_pkg.config.clear("Unattended-Upgrade") + apt_pkg.read_config_file(apt_pkg.config, "./data/50unattended-upgrades.compat") + allowed_origins = unattended_upgrade.get_allowed_origins() + #print allowed_origins + self.assertTrue("o=Google\, Inc.,a=stable" in allowed_origins) + self.assertTrue("o=MoreCorp\, eink,a=stable" in allowed_origins) + # test whitelist + pkg = self._get_mock_package() + self.assertTrue(is_allowed_origin(pkg.candidate, allowed_origins)) + + def test_blacklist(self): + # mock pkg (yeah, complicated) + pkg = self._get_mock_package() + # mock cache + cache = MockCache() + cache._depcache = MockDepCache() + cache._depcache.broken_count = 0 + cache.append(pkg) + # origins and blacklist + allowed_origins = ["o=Ubuntu"] + blacklist = ["linux-.*"] + # with blacklist pkg + self.assertFalse(check_changes_for_sanity(cache, allowed_origins, blacklist)) + # with "normal" pkg + pkg.name = "apt" + self.assertTrue(check_changes_for_sanity(cache, allowed_origins, blacklist)) + + def _get_mock_origin(self, aorigin="", label="", archive="", + site="", component=""): + origin = MockOrigin() + origin.origin = aorigin + origin.label = label + origin.archive = archive + origin.site = site + origin.compoent = component + return origin + + def _get_mock_package(self): + pkg = MockPackage() + pkg._pkg = MockPackage() + pkg._pkg.selected_state = 0 + pkg.name = "linux-image" + pkg.marked_install = True + pkg.marked_upgrade = True + pkg.marked_delete = False + pkg.candidate = MockCandidate() + pkg.candidate.origins = [self._get_mock_origin("Ubuntu"), + self._get_mock_origin(aorigin="Google, Inc.", + archive="stable"), + ] + pkg.candidate.record = {} + return pkg + + +if __name__ == "__main__": + logging.basicConfig(level=logging.DEBUG) + unittest.main() + diff --git a/test/test_pyflakes.py b/test/test_pyflakes.py new file mode 100644 index 0000000..de3536c --- /dev/null +++ b/test/test_pyflakes.py @@ -0,0 +1,14 @@ +import os +import subprocess +import unittest + +class TestPyflakesClean(unittest.TestCase): + """ ensure that the tree is pyflakes clean """ + + def test_pyflakes_clean(self): + target = os.path.join(os.path.dirname(__file__), "..", "unattended-upgrade") + self.assertEqual(subprocess.call(["pyflakes", target]), 0) + + +if __name__ == "__main__": + unittest.main() diff --git a/test/test_substitute.py b/test/test_substitute.py new file mode 100755 index 0000000..8d4a054 --- /dev/null +++ b/test/test_substitute.py @@ -0,0 +1,39 @@ +#!/usr/bin/python + +import apt +import apt_pkg +import os +import logging +import unittest +import sys + +from StringIO import StringIO + +import unattended_upgrade +from unattended_upgrade import substitute, get_allowed_origins + +class TestSubstitude(unittest.TestCase): + + def setUp(self): + # monkey patch DISTRO_{CODENAME, ID} + unattended_upgrade.DISTRO_CODENAME = "nacked" + unattended_upgrade.DISTRO_ID = "MyDistroID" + + def testSubstitute(self): + """ test if the substitute function works """ + self.assertTrue(substitute("${distro_codename}-updates"), + "nacked-updates") + self.assertTrue(substitute("${distro_id}"), "MyDistroID") + + def test_get_allowed_origins_with_substitute(self): + """ test if substitute for get_allowed_origins works """ + apt_pkg.config.clear("Unattended-Upgrade::Allowed-Origins") + apt_pkg.config.set("Unattended-Upgrade::Allowed-Origins::", + "${distro_id} ${distro_codename}-security") + l = get_allowed_origins() + self.assertTrue(("o=MyDistroID,a=nacked-security") in l) + +if __name__ == "__main__": + logging.basicConfig(level=logging.DEBUG) + unittest.main() + diff --git a/test/unattended_upgrade.py b/test/unattended_upgrade.py new file mode 120000 index 0000000..6d123e7 --- /dev/null +++ b/test/unattended_upgrade.py @@ -0,0 +1 @@ +../unattended-upgrade \ No newline at end of file diff --git a/unattended-upgrade b/unattended-upgrade new file mode 100755 index 0000000..14ac9ec --- /dev/null +++ b/unattended-upgrade @@ -0,0 +1,1011 @@ +#!/usr/bin/python +# Copyright (c) 2005-2012 Canonical Ltd +# +# AUTHOR: +# Michael Vogt +# +# This file is part of unattended-upgrades +# +# unattended-upgrades is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as published +# by the Free Software Foundation; either version 2 of the License, or (at +# your option) any later version. +# +# unattended-upgrades is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with unattended-upgrades; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# + +import apt_inst +import apt_pkg + +import copy +import datetime +import email.Charset +import fcntl +import re +import os +import string +import sys + +from email.Message import Message +from optparse import OptionParser +from StringIO import StringIO +from subprocess import Popen, PIPE + +import warnings +warnings.filterwarnings("ignore", "apt API not stable yet", FutureWarning) +import apt +import logging +import lsb_release +import signal +import subprocess + +import gettext +from gettext import gettext as _ + +# the reboot required flag file used by packages +REBOOT_REQUIRED_FILE = "/var/run/reboot-required" +MAIL_BINARY = "/usr/bin/mail" +SENDMAIL_BINARY = "/usr/sbin/sendmail" +DISTRO_CODENAME = lsb_release.get_distro_information()['CODENAME'] +DISTRO_ID = lsb_release.get_distro_information()['ID'] + +# progress information is written here +PROGRESS_LOG="/var/run/unattended-upgrades.progress" + +# set from the sigint signal handler +SIGNAL_STOP_REQUEST=False + +class UnattendedUpgradesCache(apt.Cache): + + def __init__(self, rootdir, allowed_origins): + apt.Cache.__init__(self, rootdir=rootdir) + self.allowed_origins = allowed_origins + # ensure we update the candidate versions + self.adjust_candidate_versions() + def clear(self): + apt.Cache.clear(self) + # ensure we update the candidate versions + self.adjust_candidate_versions() + def adjust_candidate_versions(self): + """ Adjust candidate versions to match highest allowed origin + + This adjusts the origin even if the candidate has a higher + version + """ + for pkg in self: + # important! this avoids downgrades below + if not pkg.is_upgradable: + continue + # check if the candidate is already pointing to a allowed + # origin and if so, do not mess with it + if is_allowed_origin(pkg.candidate, self.allowed_origins): + continue + # check if we have a version in a allowed origin that is + # not the candidate + new_cand = None + for ver in pkg.versions: + # ignore versions that the user marked with priority < 0 + # (and ensure we have a python-apt that supports this) + if hasattr(ver, "policy_priority") and ver.policy_priority < 0: + logging.debug("ignoring ver '%s' with priority < 0" % ver) + continue + if is_allowed_origin(ver, self.allowed_origins): + # leave as soon as we have the highest new candidate + new_cand = ver + break + if new_cand and new_cand != pkg.candidate: + logging.debug("adjusting candidate version: '%s'" % new_cand) + pkg.candidate = new_cand + + +class LogInstallProgress(apt.progress.base.InstallProgress): + """ Install progress that writes to self.LOG + (/var/run/unattended-upgrades.progress by default) + """ + + LOG = PROGRESS_LOG + + def status_change(self, pkg, percent, status): + f=open(self.LOG, "w") + f.write(_("Progress: %s %% (%s)") % (percent, pkg)) + f.close() + + def _fixup_fds(self): + required_fds = [ 0, 1, 2, # stdin, stdout, stderr + self.writefd, + self.write_stream.fileno(), + self.statusfd, + self.status_stream.fileno() + ] + # ensure that our required fds close on exec + for fd in required_fds[3:]: + old_flags = fcntl.fcntl(fd, fcntl.F_GETFD) + fcntl.fcntl(fd, fcntl.F_SETFD, old_flags | fcntl.FD_CLOEXEC) + # close all fds + proc_fd = "/proc/self/fd" + if os.path.exists(proc_fd): + error_count = 0 + for fdname in os.listdir(proc_fd): + try: + fd = int(fdname) + except Exception as e: + print "ERROR: can not get fd for '%s'" % fdname + if fd in required_fds: + continue + try: + os.close(fd) + #print "closed: ", fd + except OSError as e: + # there will be one fd that can not be closed + # as its the fd from pythons internal diropen() + # so its ok to ignore one close error + error_count += 1 + if error_count > 1: + print "ERROR: os.close(%s): %s" % (fd, e) + + def fork(self): + pid = os.fork() + if pid == 0: + self._fixup_fds() + return pid + + +class Unlocked: + """ context manager for unlocking the apt lock while cache.commit() + is run + """ + def __enter__(self): + try: + apt_pkg.pkgsystem_unlock() + except: + pass + def __exit__(self, exc_type, exc_value, exc_tb): + try: + apt_pkg.pkgsystem_unlock() + except: + pass + +def is_dpkg_journal_dirty(): + """ + test if the dpkg journal is dirty + (similar to debSystem::CheckUpdates) + """ + d = os.path.dirname( + apt_pkg.config.find_file("Dir::State::status"))+"/updates" + for f in os.listdir(d): + if re.match("[0-9]+", f): + return True + return False + +def signal_handler(signal, frame): + logging.warn("SIGUSR1 recieved, will stop") + global SIGNAL_STOP_REQUEST + SIGNAL_STOP_REQUEST=True + +def substitute(line): + """ substitude known mappings and return a new string + + Currently supported ${distro-release} + """ + mapping = {"distro_codename" : get_distro_codename(), + "distro_id" : get_distro_id(), + } + return string.Template(line).substitute(mapping) + +def get_distro_codename(): + return DISTRO_CODENAME + +def get_distro_id(): + return DISTRO_ID + +def get_allowed_origins_legacy(): + """ legacy support for old Allowed-Origins var """ + allowed_origins = [] + for s in apt_pkg.config.value_list("Unattended-Upgrade::Allowed-Origins"): + # if there is a ":" use that as seperator, else use spaces + if ":" in s: + (distro_id, distro_codename) = s.split(':') + else: + (distro_id, distro_codename) = s.split() + # escape "," (see LP: #824856) - i wonder if there is a simpler way? + distro_id = re.sub(r'([^\\]),', r'\1\\,', distro_id) + distro_codename = re.sub(r'([^\\]),', r'\1\\,', distro_codename) + # convert to new format + allowed_origins.append("o=%s,a=%s" % (substitute(distro_id), + substitute(distro_codename))) + return allowed_origins + +def get_allowed_origins(): + """ return a list of allowed origins from apt.conf + + This will take substitutions (like distro_id) into account. + """ + allowed_origins = get_allowed_origins_legacy() + for s in apt_pkg.config.value_list("Unattended-Upgrade::Origins-Pattern"): + allowed_origins.append(substitute(s)) + return allowed_origins + +def match_whitelist_string(whitelist, origin): + """ + take a whitelist string in the form "origin=Debian,label=Debian-Security" + and match against the given python-apt origin. A empty whitelist string + never matches anything. + """ + whitelist = whitelist.strip() + if whitelist == "": + logging.warn("empty match string matches nothing") + return False + res = True + # make "\," the html quote equivalent + whitelist = whitelist.replace("\,", "%2C") + for token in whitelist.split(","): + # strip and unquote the "," back + (what, value) = [s.strip().replace("%2C",",") + for s in token.split("=")] + #logging.debug("matching '%s'='%s' against '%s'" % (what, value, origin)) + # first char is apt-cache policy output, send is the name + # in the Release file + if what in ("o", "origin"): + res &= (value == origin.origin) + elif what in ("l", "label"): + res &= (value == origin.label) + elif what in ("a", "suite", "archive"): + res &= (value == origin.archive) + elif what in ("c", "component"): + res &= (value == origin.component) + elif what in ("site",): + res &= (value == origin.site) + return res + +def upgrade_normal(cache, pkgs_to_upgrade, logfile_dpkg): + error = None + res = False + iprogress = LogInstallProgress() + try: + with Unlocked(): + res = cache.commit(install_progress=iprogress) + except SystemError,e: + error = e + if res: + logging.info(_("All upgrades installed")) + else: + logging.error(_("Installing the upgrades failed!")) + logging.error(_("error message: '%s'") % error) + logging.error(_("dpkg returned a error! See '%s' for details") % \ + logfile_dpkg) + return res + +def upgrade_in_minimal_steps(cache, pkgs_to_upgrade, logfile_dpkg=""): + + install_log = LogInstallProgress() + install_log.LOG += ".minimal-steps" + + # setup signal handler + signal.signal(signal.SIGUSR1, signal_handler) + + # to upgrade contains the package names + to_upgrade = set(pkgs_to_upgrade) + while True: + # find smallest set + smallest_partition = to_upgrade + for pkgname in to_upgrade: + if SIGNAL_STOP_REQUEST: + logging.warn("SIGNAL recieved, stopping") + return True + pkg = cache[pkgname] + if pkg.is_upgradable: + pkg.mark_upgrade() + elif not pkg.is_installed: + pkg.mark_install() + else: + continue + changes = [pkg.name for pkg in cache.get_changes()] + if len(changes) == 1: + logging.debug("found leaf package %s" % pkg.name) + smallest_partition = changes + break + if len(changes) < len(smallest_partition): + logging.debug("found partition of size %s (%s)" % (len(changes), changes)) + smallest_partition = changes + cache.clear() + + # write progress log information + if len(pkgs_to_upgrade) > 0: + percent = (len(pkgs_to_upgrade)-len(to_upgrade)) / float(len(pkgs_to_upgrade))*100.0 + else: + percent = 100.0 + install_log.status_change(pkg=",".join(smallest_partition), + percent=percent, + status="") + # apply changes + logging.debug("applying set %s" % smallest_partition) + rewind_cache(cache, [cache[name] for name in smallest_partition]) + + try: + iprogress = LogInstallProgress() + with Unlocked(): + res = cache.commit(install_progress=iprogress) + if not res: + raise Exception("cache.commit() returned false") + cache.open() + except Exception, e: + logging.error(_("Installing the upgrades failed!")) + logging.error(_("error message: '%s'") % e) + logging.error(_("dpkg returned a error! See '%s' for details") % \ + logfile_dpkg) + return False + to_upgrade = to_upgrade-set(smallest_partition) + logging.debug("left to upgrade %s" % to_upgrade) + if len(to_upgrade) == 0: + logging.info(_("All upgrades installed")) + break + return True + +def is_allowed_origin(ver, allowed_origins): + if not ver: + return False + for origin in ver.origins: + for allowed in allowed_origins: + if match_whitelist_string(allowed, origin): + return True + return False + +def is_pkgname_in_blacklist(pkgname, blacklist): + for blacklist_regexp in blacklist: + if re.match(blacklist_regexp, pkgname): + logging.debug("skipping blacklisted package '%s'" % pkgname) + return True + return False + +def check_changes_for_sanity(cache, allowed_origins, blacklist): + if cache._depcache.broken_count != 0: + return False + for pkg in cache: + if pkg.marked_delete: + logging.debug("pkg '%s' now marked delete" % pkg.name) + return False + if pkg.marked_install or pkg.marked_upgrade: + if not is_allowed_origin(pkg.candidate, allowed_origins): + logging.debug("pkg '%s' not in allowed origin" % pkg.name) + return False + if is_pkgname_in_blacklist(pkg.name, blacklist): + return False + if pkg._pkg.selected_state == apt_pkg.SELSTATE_HOLD: + logging.debug("pkg '%s' is on hold" % pkg.name) + return False + # check if the package is unsafe to upgrade unattended + ignore_require_restart = apt_pkg.config.find_b( + "Unattended-Upgrade::IgnoreAppsRequireRestart", False) + if (pkg.marked_upgrade and + ignore_require_restart == False and + pkg.candidate.record.get("Upgrade-Requires") == "app-restart"): + logging.debug("pkg '%s' requires app-restart, not safe to upgrade unattended") + return False + return True + +def pkgname_from_deb(debfile): + # FIXME: add error checking here + try: + control = apt_inst.DebFile(debfile).control.extractdata("control") + sections = apt_pkg.TagSection(control) + return sections["Package"] + except (IOError, SystemError), e: + logging.error("failed to read deb file '%s' (%s)" % (debfile, e)) + # dumb fallback + return debfile.split("_")[0] + +def get_md5sum_for_file_in_deb(deb_file, conf_file): + dpkg_cmd = ["dpkg-deb","--fsys-tarfile", deb_file] + tar_cmd = ["tar","-x","-O", "-f","-", "."+conf_file] + md5_cmd = ["md5sum"] + dpkg_p = Popen(dpkg_cmd, stdout=PIPE) + tar_p = Popen(tar_cmd, stdin=dpkg_p.stdout, stdout=PIPE) + md5_p = Popen(md5_cmd, stdin=tar_p.stdout, stdout=PIPE) + pkg_md5sum = md5_p.communicate()[0].split()[0] + return pkg_md5sum + +# prefix is *only* needed for the build-in tests +def conffile_prompt(destFile, prefix=""): + logging.debug("check_conffile_prompt('%s')" % destFile) + pkgname = pkgname_from_deb(destFile) + + # get the conffiles for the /var/lib/dpkg/status file + status_file = apt_pkg.config.find("Dir::State::status") + tagfile = apt_pkg.TagFile(open(status_file,"r")) + conffiles = "" + for section in tagfile: + if section.get("Package") == pkgname: + logging.debug("found pkg: %s" % pkgname) + if "Conffiles" in section: + conffiles = section.get("Conffiles") + break + + # get conffile value from pkg, its ok if the new version + # does not have conffiles anymore + pkg_conffiles = "" + deb = apt_inst.DebFile(destFile) + try: + pkg_conffiles = deb.control.extractdata("conffiles").strip() + except LookupError as e: + logging.debug("No conffiles in deb '%s' (%s)" % (destFile, e)) + + # Conffiles: + # /etc/bash_completion.d/m-a c7780fab6b14d75ca54e11e992a6c11c + dpkg_status_conffiles = {} + for line in string.split(conffiles,"\n"): + # ignore empty lines + line = string.strip(line) + if not line: + continue + # show what we do + logging.debug("conffile line: '%s'", line) + l = string.split(line) + conf_file = l[0] + md5 = l[1] + if len(l) > 2: + obs = l[2] + else: + obs = None + # ignore if conffile is obsolete or does not exist + if obs == "obsolete" or not os.path.exists(prefix+conf_file): + continue + # ignore state "newconffile" until its clearer if there + # might be a dpkg prompt (LP: #936870) + if md5 == "newconffile": + continue + if (not pkg_conffiles or + not conf_file in pkg_conffiles.split("\n")): + logging.debug("'%s' not in package conffiles '%s'" % ( + conf_file, pkg_conffiles)) + continue + # record for later + dpkg_status_conffiles[conf_file] = md5 + # test against the installed file + current_md5 = apt_pkg.md5sum(open(prefix+conf_file).read()) + logging.debug("current md5: %s" % current_md5) + # hashes are the same, no conffile prompt + if current_md5 == md5: + continue + # calculate md5sum from the deb (may take a bit) + pkg_md5sum = get_md5sum_for_file_in_deb(destFile, conf_file) + logging.debug("pkg_md5sum: %s" % pkg_md5sum) + # the md5sum in the deb is unchanged, this will not + # trigger a conffile prompt + if pkg_md5sum == md5: + continue + # if we made it to this point: + # current_md5 != pkg_md5sum != md5 + # and that will trigger a conffile prompt, we can + # stop processing at this point and just return True + return True + + # now check if there are conffiles in the pkg that where not there + # in the previous version in the dpkg status file + if pkg_conffiles: + for conf_file in pkg_conffiles.split("\n"): + if (not conf_file in dpkg_status_conffiles and + os.path.exists(prefix+conf_file)): + logging.debug("found conffile '%s' in new pkg but on dpkg " + "status" % conf_file) + pkg_md5sum = get_md5sum_for_file_in_deb(destFile, conf_file) + if pkg_md5sum != apt_pkg.md5sum(open(prefix+conf_file).read()): + return True + return False + + +def dpkg_conffile_prompt(): + if not "DPkg::Options" in apt_pkg.config: + return True + options = apt_pkg.config.value_list("DPkg::Options") + for option in map(string.strip, options): + if (option == "--force-confold" or + option == "--force-confnew"): + return False + return True + + +def rewind_cache(cache, pkgs_to_upgrade): + " set the cache back to the state with packages_to_upgrade " + cache.clear() + for pkg2 in pkgs_to_upgrade: + pkg2.mark_upgrade() + + +def host(): + return os.uname()[1] + + +# *sigh* textwrap is nice, but it breaks "linux-image" into two +# seperate lines +def wrap(t, width=70, subsequent_indent=""): + out = "" + for s in t.split(): + if (len(out)-out.rfind("\n")) + len(s) > width: + out += "\n" + subsequent_indent + out += s + " " + return out + + +def setup_apt_listchanges(conf="/etc/apt/listchanges.conf"): + """ deal with apt-listchanges """ + # apt-listchanges will always send a mail if there is a mail address + # set in the config regardless of the frontend used, so set it to + # mail if we have a sendmail and to none if not (as it appears to + # not check if sendmail is there or not), debian bug #579733 + if os.path.exists(SENDMAIL_BINARY): + os.environ["APT_LISTCHANGES_FRONTEND"] = "mail" + else: + os.environ["APT_LISTCHANGES_FRONTEND"] = "none" + + +def _send_mail_using_mailx(to_address, subject, body): + mail = subprocess.Popen([ + MAIL_BINARY, "-s", subject, to_address], stdin=subprocess.PIPE) + mail.stdin.write(body) + mail.stdin.close() + ret = mail.wait() + return ret + + +def _send_mail_using_sendmail(to_address, subject, body): + # format as a proper mail + msg = Message() + charset = email.Charset.Charset("utf-8") + charset.body_encoding = email.Charset.QP + msg.set_charset(charset) + msg.set_payload(body) + msg['Subject'] = subject + msg['To'] = to_address + sendmail = subprocess.Popen( + [SENDMAIL_BINARY, "-oi", "-t"], stdin=subprocess.PIPE) + sendmail.stdin.write(msg.as_string()) + sendmail.stdin.close() + ret = sendmail.wait() + return ret + + +def send_summary_mail(pkgs, res, pkgs_kept_back, mem_log, logfile_dpkg): + " send mail (if configured in Unattended-Upgrade::Mail) " + to_email = apt_pkg.config.find("Unattended-Upgrade::Mail", "") + if not to_email: + return + # FIXME: this should say that sendmail works too but doing that no + # would break translations + if not os.path.exists(MAIL_BINARY) and not os.path.exists(SENDMAIL_BINARY): + logging.error(_("No '/usr/bin/mail', can not send mail. " + "You probably want to install the 'mailx' package.")) + return + # if the operation was successful and the user has requested to get + # mails on on errors, just exit here + if (res and + apt_pkg.config.find_b("Unattended-Upgrade::MailOnlyOnError", False)): + return + # Check if reboot-required flag is present + logging.debug("Sending mail with '%s' to '%s'" % (logfile_dpkg, to_email)) + if os.path.isfile(REBOOT_REQUIRED_FILE): + subject = _("[reboot required] unattended-upgrades result for '%s'") % host() + else: + subject = _("unattended-upgrades result for '%s'") % host() + body = _("Unattended upgrade returned: %s\n\n") % res + if os.path.isfile(REBOOT_REQUIRED_FILE): + body += _("Warning: A reboot is required to complete this upgrade.\n\n") + body += _("Packages that are upgraded:\n") + body += " " + wrap(pkgs, 70, " ") + body += "\n" + if pkgs_kept_back: + body += _("Packages with upgradable origin but kept back:\n") + body += " " + wrap(" ".join(pkgs_kept_back), 70, " ") + body += "\n" + body += "\n" + if os.path.exists(logfile_dpkg): + body += _("Package installation log:")+"\n" + body += open(logfile_dpkg).read() + body += "\n\n" + body += _("Unattended-upgrades log:\n") + body += mem_log.getvalue() + + # ensure that the message a utf8 encoded string + if type(body) is unicode: + body= body.encode("utf-8", "replace") + + if os.path.exists(SENDMAIL_BINARY): + ret = _send_mail_using_sendmail(to_email, subject, body) + elif os.path.exists(MAIL_BINARY): + ret = _send_mail_using_mailx(to_email, subject, body) + else: + raise AssertionError( + "This should never be reached, if we are here we either " + "have sendmail or mailx. Please report this as a bug.") + logging.debug("mail returned: %s" % ret) + + +def do_install(cache, pkgs_to_upgrade, options, logfile_dpkg): + # set debconf to NON_INTERACTIVE, redirect output + os.putenv("DEBIAN_FRONTEND","noninteractive"); + setup_apt_listchanges() + + # redirect to log + REDIRECT_INPUT = os.devnull + fd = os.open(REDIRECT_INPUT, os.O_RDWR) + os.dup2(fd,0) + + logging.info(_("Writing dpkg log to '%s'") % logfile_dpkg) + + # do not create log in dry-run mode, just output to stdout/stderr + if options.dry_run: + old_stdout = 1 + old_stderr = 2 + else: + fd = os.open(logfile_dpkg, os.O_RDWR|os.O_CREAT, 0644) + old_stdout = os.dup(1) + old_stderr = os.dup(2) + os.dup2(fd,1) + os.dup2(fd,2) + + try: + if (options.minimal_upgrade_steps or + # COMPAT with the mispelling + apt_pkg.config.find_b("Unattended-Upgrades::MinimalSteps", False) or + apt_pkg.config.find_b("Unattended-Upgrade::MinimalSteps", False)): + open("/var/run/unattended-upgrades.pid", "w").write("%s" % os.getpid()) + # try upgrade all "pkgs" in minimal steps + pkg_install_success = upgrade_in_minimal_steps( + cache, [pkg.name for pkg in pkgs_to_upgrade], logfile_dpkg) + else: + pkg_install_success = upgrade_normal( + cache, [pkg.name for pkg in pkgs_to_upgrade], logfile_dpkg) + except Exception as e: + # print unhandled exceptions here this way, while stderr is redirected + os.write(old_stderr, "Exception: %s" % e) + + # restore + os.dup2(old_stdout, 1) + os.dup2(old_stderr, 2) + + return pkg_install_success + + +def _setup_alternative_rootdir(rootdir): + # clear system unattended-upgrade stuff + apt_pkg.config.clear("Unattended-Upgrade") + # read rootdir (taken from apt.Cache, but we need to run it + # here before the cache gets initialized + if os.path.exists(rootdir+"/etc/apt/apt.conf"): + apt_pkg.read_config_file(apt_pkg.config, + rootdir + "/etc/apt/apt.conf") + if os.path.isdir(rootdir+"/etc/apt/apt.conf.d"): + apt_pkg.read_config_dir(apt_pkg.config, + rootdir + "/etc/apt/apt.conf.d") + +def _get_logdir(): + logdir= apt_pkg.config.find_dir( + "Unattended-Upgrade::LogDir", + # COMPAT only + apt_pkg.config.find_dir("APT::UnattendedUpgrades::LogDir", + "/var/log/unattended-upgrades/")) + return logdir + + +def _setup_logging(options): + # ensure this is run only once + if len(logging.root.handlers) > 0: + return + + # init the logging + logdir = _get_logdir() + logfile = os.path.join( + logdir, + apt_pkg.config.find( + "Unattended-Upgrade::LogFile", + # COMPAT only + apt_pkg.config.find("APT::UnattendedUpgrades::LogFile", + "unattended-upgrades.log"))) + + if not options.dry_run and not os.path.exists(os.path.dirname(logfile)): + os.makedirs(os.path.dirname(logfile)) + + logging.basicConfig(level=logging.INFO, + format='%(asctime)s %(levelname)s %(message)s', + filename=logfile) + + # additional logging + logger = logging.getLogger() + mem_log = StringIO() + if options.debug: + logger.setLevel(logging.DEBUG) + stdout_handler = logging.StreamHandler(sys.stdout) + logger.addHandler(stdout_handler) + if apt_pkg.config.find("Unattended-Upgrade::Mail", ""): + mem_log_handler = logging.StreamHandler(mem_log) + logger.addHandler(mem_log_handler) + return mem_log + + +def main(options, rootdir=""): + + # useful for testing + if rootdir: + _setup_alternative_rootdir(rootdir) + + # setup logging + mem_log = _setup_logging(options) + + # format (origin, archive), e.g. ("Ubuntu","dapper-security") + allowed_origins = get_allowed_origins() + + # pkgs that are (for some reason) not save to install + blacklisted_pkgs = apt_pkg.config.value_list("Unattended-Upgrade::Package-Blacklist") + logging.info(_("Initial blacklisted packages: %s"), " ".join(blacklisted_pkgs)) + logging.info(_("Starting unattended upgrades script")) + + # display available origin + logging.info(_("Allowed origins are: %s") % map(str,allowed_origins)) + + # check if the journal is dirty and if so, take emergceny action + # the alternative is to leave the system potentially unsecure until + # the user comes in and fixes + if (is_dpkg_journal_dirty() and + apt_pkg.config.find_b("Unattended-Upgrade::AutoFixInterruptedDpkg", True)): + # ensure the dpkg database is not already locked (LP: #754330) + admindir = os.path.dirname(apt_pkg.config.find("Dir::State::Status")) + lockfd = apt_pkg.get_lock(os.path.join(admindir, "lock"), False) + if lockfd > 0: + logging.warning(_("Unclean dpkg state detected, trying to correct")) + print _("Unclean dpkg state detected, trying to correct") + env = copy.copy(os.environ) + env["DEBIAN_FRONTEND"] = "noninteractive" + try: + os.close(lockfd) + output = subprocess.check_output( + ["dpkg", "--force-confold", "--configure", "-a"], env=env) + except subprocess.CalledProcessError as e: + output = e.output + logging.warning(_("dpkg --configure -a output:\n%s" % output)) + else: + logging.debug("Unclean dpkg state, but locked, another package manager working?") + + # check and get lock + try: + apt_pkg.pkgsystem_lock() + except SystemError, e: + logging.error(_("Lock could not be acquired (another package " + "manager running?)")) + print _("Cache lock can not be acquired, exiting") + sys.exit(1) + + # get a cache + cache = UnattendedUpgradesCache(rootdir=rootdir, + allowed_origins=allowed_origins) + if cache._depcache.broken_count > 0: + print _("Cache has broken packages, exiting") + logging.error(_("Cache has broken packages, exiting")) + sys.exit(1) + # speed things up with latest apt + actiongroup = apt_pkg.ActionGroup(cache._depcache) + actiongroup # pyflakes + + # find out about the packages that are upgradable (in a allowed_origin) + pkgs_to_upgrade = [] + pkgs_kept_back = [] + pkgs_auto_removable = set([pkg.name for pkg in cache + if pkg.is_auto_removable]) + + # now do the actual upgrade + for pkg in cache: + if options.debug and pkg.is_upgradable: + logging.debug("Checking: %s (%s)" % (pkg.name, map(str, pkg.candidate.origins))) + if (pkg.is_upgradable and + not is_pkgname_in_blacklist(pkg.name, blacklisted_pkgs) and + is_allowed_origin(pkg.candidate, allowed_origins)): + try: + pkg.mark_upgrade() + if check_changes_for_sanity(cache, allowed_origins, + blacklisted_pkgs): + # add to packages to upgrade + pkgs_to_upgrade.append(pkg) + # re-eval pkgs_kept_back as the resolver may fail to + # directly upgrade a pkg, but that may work during + # a subsequent operation, see debian bug #639840 + for pkgname in pkgs_kept_back: + if (cache[pkgname].marked_install or + cache[pkgname].marked_upgrade): + pkgs_kept_back.remove(pkgname) + pkgs_to_upgrade.append(cache[pkgname]) + else: + logging.debug("sanity check failed") + rewind_cache(cache, pkgs_to_upgrade) + pkgs_kept_back.append(pkg.name) + except SystemError, e: + # can't upgrade + logging.warning(_("package '%s' upgradable but fails to be marked for upgrade (%s)") % (pkg.name, e)) + rewind_cache(cache, pkgs_to_upgrade) + pkgs_kept_back.append(pkg.name) + + + pkgs_to_upgrade.sort(key=lambda p: p.name) + pkgs = "\n".join([pkg.name for pkg in pkgs_to_upgrade]) + logging.debug("pkgs that look like they should be upgraded: %s" % pkgs) + + # download what looks good + if options.debug: + fetcher = apt_pkg.Acquire(apt.progress.text.AcquireProgress()) + else: + fetcher = apt_pkg.Acquire() + list = apt_pkg.SourceList() + list.read_main_list() + recs = cache._records + pm = apt_pkg.PackageManager(cache._depcache) + try: + pm.get_archives(fetcher,list,recs) + except SystemError, e: + logging.error(_("GetArchives() failed: '%s'") % e) + res = fetcher.run() + logging.debug("fetch.run() result: %s" % res) + + if dpkg_conffile_prompt(): + # now check the downloaded debs for conffile conflicts and build + # a blacklist + for item in fetcher.items: + logging.debug("%s" % item) + if item.status == item.STAT_ERROR: + print _("An error ocured: '%s'") % item.error_text + logging.error(_("An error ocured: '%s'") % item.error_text) + if not item.complete: + print _("The URI '%s' failed to download, aborting") % item.desc_uri + logging.error(_("The URI '%s' failed to download, aborting") % item.desc_uri) + sys.exit(1) + if not os.path.exists(item.destfile): + print _("Download finished, but file '%s' not there?!?" % item.destfile) + logging.error("Download finished, but file '%s' not there?!?" % item.destfile) + sys.exit(1) + if not item.is_trusted: + blacklisted_pkgs.append(pkgname_from_deb(item.destfile)) + if conffile_prompt(item.destfile): + # skip package (means to re-run the whole marking again + # and making sure that the package will not be pulled in by + # some other package again!) + # + # print to stdout to ensure that this message is part of + # the cron mail (only if no summary mail is requested) + email = apt_pkg.config.find("Unattended-Upgrade::Mail", "") + if not email: + print _("Package '%s' has conffile prompt and needs to be upgraded manually") % pkgname_from_deb(item.destfile) + # log to the logfile + logging.warning(_("Package '%s' has conffile prompt and needs to be upgraded manually") % pkgname_from_deb(item.destfile)) + blacklisted_pkgs.append(pkgname_from_deb(item.destfile)) + pkgs_kept_back.append(pkgname_from_deb(item.destfile)) + + + # redo the selection about the packages to upgrade based on the new + # blacklist + logging.debug("blacklist: %s" % blacklisted_pkgs) + # find out about the packages that are upgradable (in a allowed_origin) + if len(blacklisted_pkgs) > 0: + cache.clear() + old_pkgs_to_upgrade = pkgs_to_upgrade[:] + pkgs_to_upgrade = [] + for pkg in old_pkgs_to_upgrade: + logging.debug("Checking (blacklist): %s" % (pkg.name)) + pkg.mark_upgrade() + if check_changes_for_sanity(cache, allowed_origins, + blacklisted_pkgs): + pkgs_to_upgrade.append(pkg) + else: + if not (pkg.name in pkgs_kept_back): + pkgs_kept_back.append(pkg.name) + logging.info(_("package '%s' not upgraded") % pkg.name) + cache.clear() + for pkg2 in pkgs_to_upgrade: + pkg2.mark_upgrade() + else: + logging.debug("dpkg is configured not to cause conffile prompts") + + # do auto-remove + if apt_pkg.config.find_b("Unattended-Upgrade::Remove-Unused-Dependencies", False): + now_auto_removable = set([pkg.name for pkg in cache + if pkg.is_auto_removable]) + for pkgname in now_auto_removable-pkgs_auto_removable: + logging.debug("marking %s for remove" % pkgname) + cache[pkgname].mark_delete() + logging.info(_("Packages that are auto removed: '%s'") % + " ".join(now_auto_removable-pkgs_auto_removable)) + + logging.debug("InstCount=%i DelCount=%i BrokenCout=%i" % (cache._depcache.inst_count, cache._depcache.del_count, cache._depcache.broken_count)) + + # exit if there is nothing to do and nothing to report + if (len(pkgs_to_upgrade) == 0) and (len(pkgs_kept_back) == 0): + logging.info(_("No packages found that can be upgraded unattended")) + return + + # check if its configured for install on shutdown, if so, the + # environment UNATTENDED_UPGRADES_FORCE_INSTALL_ON_SHUTDOWN will + # be set by the unatteded-upgrades-shutdown script + if (not "UNATTENDED_UPGRADES_FORCE_INSTALL_ON_SHUTDOWN" in os.environ and + apt_pkg.config.find_b("Unattended-Upgrade::InstallOnShutdown", False)): + logger = logging.getLogger() + logger.debug("Configured to install on shutdown, so exiting now") + return + + # check if we are in dry-run mode + if options.dry_run: + logging.info("Option --dry-run given, *not* performing real actions") + apt_pkg.config.set("Debug::pkgDPkgPM","1") + + # do the install based on the new list of pkgs + pkgs = " ".join([pkg.name for pkg in pkgs_to_upgrade]) + logging.info(_("Packages that are upgraded: %s" % pkgs)) + + # get log + now = datetime.datetime.now() + logfile_dpkg = os.path.join( + _get_logdir(), 'unattended-upgrades-dpkg_%s.log' % now.isoformat('_')) + + # only perform install step if we actually have packages to install + pkg_install_success = None + shutdown_lock = -1 + if len(pkgs_to_upgrade) > 0: + # lock for the shutdown check - its fine if the system + # is shutdown while downloading but not so much while installing + shutdown_lock = apt_pkg.get_lock("/var/run/unattended-upgrades.lock") + # do install + pkg_install_success = do_install( + cache, pkgs_to_upgrade, options, logfile_dpkg) + + # send a mail (if needed) + if not options.dry_run: + send_summary_mail( + pkgs, pkg_install_success, pkgs_kept_back, mem_log, logfile_dpkg) + + # auto-reboot (if required and the config for this is set + if (apt_pkg.config.find_b("Unattended-Upgrade::Automatic-Reboot", False) and + os.path.exists(REBOOT_REQUIRED_FILE)): + if shutdown_lock > 0: + os.close(shutdown_lock) + logging.warning("Found %s, rebooting" % REBOOT_REQUIRED_FILE) + subprocess.call(["/sbin/reboot"]) + + +if __name__ == "__main__": + localesApp="unattended-upgrades" + localesDir="/usr/share/locale" + gettext.bindtextdomain(localesApp, localesDir) + gettext.textdomain(localesApp) + + # init the options + parser = OptionParser() + parser.add_option("-d", "--debug", + action="store_true", dest="debug", default=False, + help=_("print debug messages")) + parser.add_option("", "--dry-run", + action="store_true", default=False, + help=_("Simulation, download but do not install")) + parser.add_option("", "--minimal_upgrade_steps", + action="store_true", default=False, + help=_("Upgrade in minimal steps (and allow interrupting with SIGINT")) + (options, args) = parser.parse_args() + + if os.getuid() != 0: + print _("You need to be root to run this application") + sys.exit(1) + + # nice & ionce + os.nice(19) + IONICE="/usr/bin/ionice" + if os.path.exists(IONICE): + with open(os.devnull, "w") as fstderr: + subprocess.call([IONICE, "-c3", "-p",str(os.getpid())], + stderr=fstderr) + + # ensure that we are not killed when the terminal goes away e.g. on + # shutdown + signal.signal(signal.SIGHUP, signal.SIG_IGN) + + # run the main code + main(options) diff --git a/unattended-upgrade-shutdown b/unattended-upgrade-shutdown new file mode 100755 index 0000000..b046480 --- /dev/null +++ b/unattended-upgrade-shutdown @@ -0,0 +1,154 @@ +#!/usr/bin/python +# Copyright (c) 2009 Canonical Ltd +# +# AUTHOR: +# Michael Vogt +# +# unattended-upgrade-shutdown - helper that checks if a +# unattended-upgrade is in progress and waits until it exists +# +# This file is part of unattended-upgrades +# +# unattended-upgrades is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as published +# by the Free Software Foundation; either version 2 of the License, or (at +# your option) any later version. +# +# unattended-upgrades is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with unattended-upgrades; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# + +import copy +import signal +import struct +import sys +import fcntl +import time +import logging +import logging.handlers +import gettext +import subprocess +import os.path + +from optparse import OptionParser +from gettext import gettext as _ + +try: + import apt_pkg +except: + # if there is no python-apt no unattended-upgrades can run so not + # need to stop the shutdown + logging.exception("importing of apt_pkg failed, exiting") + sys.exit(0) + +def do_usplash(msg): + if os.path.exists("/sbin/usplash_write"): + logging.debug("Running usplash_write") + subprocess.call(["/sbin/usplash_write","TEXT", msg]) + subprocess.call(["/sbin/usplash_write","PULSATE"]) + +def do_plymouth(msg): + if os.path.exists("/bin/plymouth"): + logging.debug("Running plymouth --text") + subprocess.call(["/bin/plymouth","message", "--text", msg]) + +def log_msg(msg, level=logging.WARN): + """ helper that will print msg to usplash, plymouth, console """ + logging.log(level, msg) + do_plymouth(msg) + do_usplash(msg) + +def log_progress(): + """ helper to log the install progress (if any) """ + # wait a some seconds and try again + msg = _("Unattended-upgrade in progress during shutdown, " + "sleeping for 5s") + # progress info + progress = "/var/run/unattended-upgrades.progress" + if os.path.exists(progress): + msg += "\n" + open(progress).read() + # log it + log_msg(msg) + +if __name__ == "__main__": + # setup gettext + localesApp="unattended-upgrades" + localesDir="/usr/share/locale" + gettext.bindtextdomain(localesApp, localesDir) + gettext.textdomain(localesApp) + + parser = OptionParser() + parser.add_option("", "--debug", + action="store_true", dest="debug", default=False, + help="print debug messages") + parser.add_option("", "--delay", default=10, + help="delay in minutes to wait for unattended-upgrades") + parser.add_option("", "--lock-file", + default="/var/run/unattended-upgrades.lock", + help="lock file location") + (options, args) = parser.parse_args() + + # setup logging + level = logging.INFO + if options.debug: + level = logging.DEBUG + + # use a normal logfile instead of syslog too as on shutdown its too + # easy to get syslog killed + logfile = "/var/log/unattended-upgrades/unattended-upgrades-shutdown.log" + logging.basicConfig(filename=logfile, + level=level, + format="%(asctime)s %(levelname)s - %(message)s") + + # check if we need to run unattended-upgrades on shutdown and if so, + # run it + p = None + apt_pkg.init_config() + if apt_pkg.config.find_b("Unattended-Upgrade::InstallOnShutdown", False): + env = copy.copy(os.environ) + env["UNATTENDED_UPGRADES_FORCE_INSTALL_ON_SHUTDOWN"] = "1" + logging.debug("starting unattended-upgrades in shutdown mode") + p = subprocess.Popen(["unattended-upgrade"], env=env) + log_msg(_("Running unattended-upgrades in shutdown mode")) + while True: + log_progress() + if p.poll() is not None: + break + time.sleep(5) + + # run the monitoring loop and keep the "UI" updated + start_time = time.time() + lock_was_taken = False + while True: + res = apt_pkg.get_lock(options.lock_file) + logging.debug("get_lock returned %i" % res) + # exit here if there is no lock + if res > 0: + logging.debug("lock not taken") + break + lock_was_taken = True + # signal unattended-upgrades to stop + p = "/var/run/unattended-upgrades.pid" + if os.path.exists(p): + pid = int(open(p).read()) + logging.debug("found running unattended-upgrades pid %s" % pid) + os.kill(pid, signal.SIGUSR1) + # show log + log_progress() + time.sleep(5) + if (time.time() - start_time) > options.delay*60: + logging.warning(_("Giving up on lockfile after %s delay") % options.delay) + sys.exit(1) + + # add finished info to the log/terminal to help tracking down + # LP: #434835 + if lock_was_taken: + # re-use existing string + log_msg(_("All upgrades installed"), logging.INFO) + sys.exit(0)