Puppet Class: nexus

Defined in:
manifests/init.pp

Summary

Install and configure Sonatype Nexus Repository Manager 3.

Overview

Examples:

class{ 'nexus':
  version => '3.37.3-02',
}

Parameters:

  • version (Pattern[/3.\d+.\d+-\d+/])

    The version to download, install and manage.

  • download_folder (Stdlib::Absolutepath)

    Destination folder of the downloaded archive.

  • download_site (Stdlib::HTTPUrl)

    Download uri which will be appended with filename of the archive to download.

  • download_proxy (Optional[Stdlib::HTTPUrl])

    Proxyserver address which will be used to download the archive file.

  • install_root (Stdlib::Absolutepath)

    The root filesystem path where the downloaded archive will be extracted to.

  • work_dir (Stdlib::Absolutepath)

    The nexus repository manager working directory which contains the embedded database and local blobstores.

  • user (String[1])

    The operation system user used to start the nexus repository manager service.

  • group (String[1])

    The operation system group used to start the nexus repository manager service.

  • host (Stdlib::Host)

    The bind address where the nexus repository manager service should bind to.

  • port (Stdlib::Port)

    The port which the nexus repository manager service should use.

  • manage_api_resources (Boolean)

    Set if this module should manage resources which require to be set over the nexus repository manager rest api.

  • manage_config (Boolean)

    Set if this module should manage the config file of nexus repository manager.

  • manage_user (Boolean)

    Set if this module should manage the creation of the operation system user.

  • manage_work_dir (Boolean)

    Set if this module should manage the work directory of the nexus repository manager.

  • purge_installations (Boolean)

    Set this option if you want old installations of nexus repository manager to get automatically deleted.

  • purge_default_repositories (Boolean)

    Set this option if you want to remove the default created maven and nuget repositories.

See Also:



44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# File 'manifests/init.pp', line 44

class nexus (
  Pattern[/3.\d+.\d+-\d+/] $version,
  Stdlib::Absolutepath $download_folder,
  Stdlib::HTTPUrl $download_site,
  Optional[Stdlib::HTTPUrl] $download_proxy,
  Stdlib::Absolutepath $install_root,
  Stdlib::Absolutepath $work_dir,
  String[1] $user,
  String[1] $group,
  Stdlib::Host $host,
  Stdlib::Port $port,
  Boolean $manage_api_resources,
  Boolean $manage_config,
  Boolean $manage_user,
  Boolean $manage_work_dir,
  Boolean $purge_installations,
  Boolean $purge_default_repositories,
) {
  include stdlib

  contain nexus::user
  contain nexus::package

  if $manage_config {
    contain nexus::config

    Class['nexus::package'] -> Class['nexus::config::properties'] ~> Class['nexus::service']
  }

  contain nexus::service

  Class['nexus::user'] -> Class['nexus::package'] ~> Class['nexus::service']

  Class['nexus::service']
  -> Nexus_user <| |>
  -> Nexus_setting <| |>
  -> Nexus_blobstore <| ensure == 'present' |>
  -> Nexus_repository <| |>
  -> Nexus_blobstore <| ensure == 'absent' |>
}