X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=README.md;h=cfad084da7fe8cb55d4e3226e23adb0ef91bea13;hb=efc728bfb53fabd9db38046edbfd803717fa1edd;hp=8c3819b262e9133f2929b65cb778dbf6b31fcb07;hpb=9ad4fd682d3223fbd6be3192e5841c366c156cf6;p=puppet-modules%2Fpuppetlabs-apt.git diff --git a/README.md b/README.md index 8c3819b..cfad084 100644 --- a/README.md +++ b/README.md @@ -30,12 +30,12 @@ Apt (Advanced Package Tool) is a package manager available on Debian, Ubuntu, an ### What apt affects -* Your system's `preferences.list` file and `preferences.list.d` directory +* Your system's `preferences` file and `preferences.d` directory * Your system's `sources.list` file and `sources.list.d` directory * System repositories * Authentication keys -**Note:** This module offers `purge` parameters which, if set to 'true', **destroy** any configuration on the node's `sources.list(.d)` and `preferences.list(.d)` that you haven't declared through Puppet. The default for these parameters is 'false'. +**Note:** This module offers `purge` parameters which, if set to 'true', **destroy** any configuration on the node's `sources.list(.d)` and `preferences(.d)` that you haven't declared through Puppet. The default for these parameters is 'false'. ### Beginning with apt @@ -150,16 +150,21 @@ apt::source { 'puppetlabs': ### Configure Apt from Hiera +Instead of specifying your sources directly as resources, you can instead just +include the `apt` class, which will pick up the values automatically from +hiera. + ~~~yaml apt::sources: 'debian_unstable': + comment: 'This is the iWeb Debian unstable mirror' location: 'http://debian.mirror.iweb.ca/debian/' release: 'unstable' repos: 'main contrib non-free' + pin: '-10' key: - id: '9AA38DCD55BE302B' + id: 'A1BD8E9D78F7FE5C3E65D8AF8B48AD6246925553' server: 'subkeys.pgp.net' - pin: '-10' include: src: true deb: true @@ -237,13 +242,15 @@ Main class, includes all other classes. * 'sources.list.d': Specifies whether to purge any unmanaged entries from `sources.list.d`. Valid options: 'true' and 'false'. Default: 'false'. - * 'preferences.list': Specifies whether to purge any unmanaged entries from `preferences.list`. Valid options: 'true' and 'false'. Default: 'false'. + * 'preferences': Specifies whether to purge any unmanaged entries from `preferences`. Valid options: 'true' and 'false'. Default: 'false'. - * 'preferences.list.d': Specifies whether to purge any unmanaged entries from `preferences.list.d`. Valid options: 'true' and 'false'. Default: 'false'. + * 'preferences.d': Specifies whether to purge any unmanaged entries from `preferences.d`. Valid options: 'true' and 'false'. Default: 'false'. * `settings`: Creates new `apt::setting` resources. Valid options: a hash to be passed to the [`create_resources` function](https://docs.puppetlabs.com/references/latest/function.html#createresources). Default: {}. -* `sources`: Creates new `apt::setting` resources. Valid options: a hash to be passed to the [`create_resources` function](https://docs.puppetlabs.com/references/latest/function.html#createresources). Default: {}. +* `sources`: Creates new `apt::source` resources. Valid options: a hash to be passed to the [`create_resources` function](https://docs.puppetlabs.com/references/latest/function.html#createresources). Default: {}. + +* `pins`: Creates new `apt::pin` resources. Valid options: a hash to be passed to the [`create_resources` function](https://docs.puppetlabs.com/references/latest/function.html#createresources). Default: {}. * `update`: Configures various update settings. Valid options: a hash made up from the following keys: @@ -460,12 +467,14 @@ Manages the GPG keys that Apt uses to authenticate packages. This module is tested and officially supported on Debian 6 and 7 and Ubuntu 10.04, 12.04, and 14.04. Testing on other platforms has been light and cannot be guaranteed. +This module is not designed to be split across [run stages](https://docs.puppetlabs.com/puppet/latest/reference/lang_run_stages.html). + ### Adding new sources or PPAs If you are adding a new source or PPA and trying to install packages from the new source or PPA on the same Puppet run, your `package` resource should depend on `Class['apt::update']`, in addition to depending on the `Apt::Source` or the `Apt::Ppa`. You can also add [collectors](https://docs.puppetlabs.com/puppet/latest/reference/lang_collectors.html) to ensure that all packages happen after `apt::update`, but this can lead to dependency cycles and has implications for [virtual resources](https://docs.puppetlabs.com/puppet/latest/reference/lang_collectors.html#behavior). ~~~puppet -Class['apt::update'] -> Package<| |> +Class['apt::update'] -> Package <| provider == 'apt' |> ~~~ ## Development