|
7 | 7 | # $install_images:: Download and extract the discovery image |
8 | 8 | # |
9 | 9 | # === Advanced parameters: |
| 10 | +# $enabled:: Whether the module is enabled or disabled. |
| 11 | +# |
| 12 | +# $version:: The version to ensure |
| 13 | +# |
| 14 | +# $listen_on:: When enabled, it's configured to listen on HTTPS (default), HTTP or both. |
10 | 15 | # |
11 | 16 | # $tftp_root:: TFTP root directory where extracted discovery image will be installed |
12 | 17 | # |
|
15 | 20 | # $image_name:: tarball with images |
16 | 21 | # |
17 | 22 | class foreman_proxy::plugin::discovery ( |
| 23 | + Boolean $enabled = true, |
| 24 | + Optional[String] $version = undef, |
| 25 | + Foreman_proxy::ListenOn $listen_on = 'https', |
18 | 26 | Boolean $install_images = $foreman_proxy::plugin::discovery::params::install_images, |
19 | 27 | Stdlib::Absolutepath $tftp_root = $foreman_proxy::plugin::discovery::params::tftp_root, |
20 | 28 | Stdlib::HTTPUrl $source_url = $foreman_proxy::plugin::discovery::params::source_url, |
21 | 29 | String $image_name = $foreman_proxy::plugin::discovery::params::image_name, |
22 | 30 | ) inherits foreman_proxy::plugin::discovery::params { |
23 | | - foreman_proxy::plugin { 'discovery': |
| 31 | + foreman_proxy::plugin::module { 'discovery': |
| 32 | + enabled => $enabled, |
| 33 | + feature => 'Discovery', |
| 34 | + listen_on => $listen_on, |
| 35 | + version => $version, |
24 | 36 | } |
25 | 37 |
|
26 | | - foreman_proxy::feature { 'Discovery': } |
27 | | - |
28 | 38 | if $install_images { |
29 | 39 | $tftp_root_clean = regsubst($tftp_root, '/$', '') |
30 | 40 |
|
|
0 commit comments