Puppet Class: minio

Defined in:
manifests/init.pp

Summary

Manages a Minio installation on various Linux/BSD operating systems.

Overview

Copyright


Copyright 2017-2021 Daniel S. Reichenbach <kogitoapp.com>

Examples:

class { 'minio':
    package_ensure                => 'present',
    owner                         => 'minio',
    group                         => 'minio',
    base_url                      => 'https://dl.minio.io/server/minio/release',
    version                       => 'RELEASE.2021-08-20T18-32-01Z',
    checksum                      => '0bf72d6fd0a88fee35ac598a1e7a5c90c78b53b6db3988414e34535fb6cf420c',
    checksum_type                 => 'sha256',
    configuration_directory       => '/etc/minio',
    installation_directory        => '/opt/minio',
    storage_root                  => '/var/minio',
    listen_ip                     => '127.0.0.1',
    listen_port                   => 9000,
    configuration                 => {
        'MINIO_ROOT_USER'     => 'admin',
        'MINIO_ROOT_PASSWORD' => 'password',
        'MINIO_REGION_NAME'   => 'us-east-1',
    },
    manage_service                => true,
    service_template              => 'minio/systemd.erb',
    service_provider              => 'systemd',
    service_ensure                => 'running',
    manage_server_installation    => true,
    manage_client_installation    => true,
    client_package_ensure         => 'present',
    client_base_url               => 'https://dl.minio.io/client/mc/release',
    client_version                => 'RELEASE.2021-07-27T06-46-19Z',
    client_checksum               => '0df81285771e12e16a0c4c2f5e0ebc700e66abb8179013cc740d48b0abad49be',
    client_checksum_type          => 'sha256',
    client_installation_directory => '/opt/minioclient',
    cert_ensure                   => 'present',
    cert_directory                => '/etc/minio/certs',
    default_cert_name             => 'miniodefault',
    default_cert_configuration    => {
      'source_path'      => 'puppet:///modules/minio/examples',
      'source_cert_name' => 'localhost',
      'source_key_name'  => 'localhost',
    },
    additional_certs              => {
      'example' => {
        'source_path'      => 'puppet:///modules/minio/examples',
        'source_cert_name' => 'example.test',
        'source_key_name'  => 'example.test',
      }
    },
    custom_configuration_file_path => '/etc/default/minio',
}

Parameters:

  • package_ensure (Enum['present', 'absent'])

    Decides if the ‘minio` binary will be installed. Default: `present`

  • manage_user (Boolean)

    Should we manage provisioning the user? Default: ‘true`

  • manage_group (Boolean)

    Should we manage provisioning the group? Default: ‘true`

  • manage_home (Boolean)

    Should we manage provisioning the home directory? Default: ‘true`

  • owner (String)

    The user owning minio and its’ files. Default: ‘minio’

  • group (String)

    The group owning minio and its’ files. Default: ‘minio’

  • home (Optional[Stdlib::Absolutepath])

    Qualified path to the users’ home directory. Default: empty

  • base_url (Stdlib::HTTPUrl)

    Download base URL for the server. Default: Github. Can be used for local mirrors.

  • version (String)

    Server release version to be installed.

  • checksum (String)

    Checksum for the server binary.

  • checksum_type (String)

    Type of checksum used to verify the server binary being installed. Default: ‘sha256`

  • configuration_directory (Stdlib::Absolutepath)

    Directory holding Minio configuration file. Default: ‘/etc/minio`

  • installation_directory (Stdlib::Absolutepath)

    Target directory to hold the minio installation. Default: ‘/opt/minio`

  • storage_root (Variant[Stdlib::Absolutepath, Array[Stdlib::Absolutepath]])

    Directory or directories where minio will keep all data. Default: ‘/var/minio`

  • listen_ip (Stdlib::IP::Address)

    IP address on which Minio should listen to requests.

  • listen_port (Stdlib::Port)

    Port on which Minio should listen to requests.

  • configuration (Hash[String[1], Variant[String, Integer]])

    Hash with environment settings for Minio.

  • manage_service (Boolean)

    Should we manage a server service definition for Minio? Default: ‘true`

  • service_ensure (Stdlib::Ensure::Service)

    Defines the state of the minio server service. Default: ‘running`

  • service_template (String)

    Path to the server service template file.

  • service_provider (String)

    Which service provider do we use?

  • manage_server_installation (Boolean)

    Decides if puppet should manage the minio server installation.

  • manage_client_installation (Boolean)

    Decides if puppet should manage the minio client installation.

  • client_package_ensure (Enum['present', 'absent'])

    Decides if the ‘mc` client binary will be installed. Default: `present`

  • client_base_url (Stdlib::HTTPUrl)

    Download base URL for the minio client. Default: Github. Can be used for local mirrors.

  • client_version (String)

    Client release version to be installed.

  • client_checksum (String)

    Checksum for the client binary.

  • client_checksum_type (String)

    Type of checksum used to verify the client binary being installed. Default: ‘sha256`

  • client_installation_directory (Stdlib::Absolutepath)

    Target directory to hold the minio client installation. Default: ‘/opt/minioclient`

  • client_binary_name (String)

    Target name of the minio client binary. Use this to avoid collisions with another ‘mc`.

  • client_aliases (Hash)

    List of aliases to add to the minio client configuration. For parameter description see ‘minio_client_alias`.

  • purge_unmanaged_client_aliases (Boolean)

    Decides if puppet should purge unmanaged minio client aliases

  • cert_ensure (Enum['present', 'absent'])

    Decides if minio certificates binary will be installed.

  • cert_directory (Stdlib::Absolutepath)

    Directory where minio will keep all cerfiticates.

  • default_cert_name (Optional[String[1]])

    Name of the default certificate. If no value provided, ‘miniodefault` is going to be used.

  • default_cert_configuration (Optional[Hash])

    Hash with the configuration for the default certificate. See ‘certs::site` of the `broadinstitute/certs` module for parameter descriptions.

  • additional_certs (Optional[Hash])

    Hash of the additional certificates to deploy. The key is a directory name, value is a hash of certificate configuration. See ‘certs::site` of the `broadinstitute/certs` module for parameter descriptions. Important: if you use additional certificates, their corresponding SAN names should be filled for SNI to work.

  • custom_configuration_file_path (Optional[Stdlib::Absolutepath])

    Optional custom location of the minio environment file.

Author:

  • Daniel S. Reichenbach <daniel@kogitoapp.com>

  • Evgeny Soynov <esoynov@kogito.network>



143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
# File 'manifests/init.pp', line 143

class minio (
  Enum['present', 'absent'] $package_ensure,

  Boolean $manage_user,
  Boolean $manage_group,
  Boolean $manage_home,
  String $owner,
  String $group,
  Optional[Stdlib::Absolutepath] $home,

  Stdlib::HTTPUrl $base_url,
  String $version,
  String $checksum,
  String $checksum_type,
  Stdlib::Absolutepath $configuration_directory,
  Stdlib::Absolutepath $installation_directory,
  Variant[Stdlib::Absolutepath, Array[Stdlib::Absolutepath]] $storage_root,
  Stdlib::IP::Address $listen_ip,
  Stdlib::Port $listen_port,

  Hash[String[1], Variant[String, Integer]] $configuration,

  Boolean $manage_service,
  Stdlib::Ensure::Service $service_ensure,
  String $service_template,
  String $service_provider,

  Boolean $manage_server_installation,
  Boolean $manage_client_installation,
  Enum['present', 'absent'] $client_package_ensure,
  Stdlib::HTTPUrl $client_base_url,
  String $client_version,
  String $client_checksum,
  String $client_checksum_type,
  Stdlib::Absolutepath $client_installation_directory,
  String $client_binary_name,
  Hash $client_aliases,
  Boolean $purge_unmanaged_client_aliases,
  Enum['present', 'absent'] $cert_ensure,
  Stdlib::Absolutepath $cert_directory,
  Optional[String[1]] $default_cert_name,
  Optional[Hash] $default_cert_configuration,
  Optional[Hash] $additional_certs,
  Optional[Stdlib::Absolutepath] $custom_configuration_file_path
  ) {

  include ::minio::server
  include ::minio::client

  Class['minio::server'] -> Class['minio::client']
}