nomad

deprecated
Configures Nomad by Hashicorp

19,571 downloads

17,808 latest version

4.6 quality score

Version information

  • 0.0.3 (latest)
  • 0.0.2
  • 0.0.1
released Apr 15th 2016
This version is compatible with:
  • RedHat
    ,
    CentOS
    ,
    Scientific Linux
    ,
    Oracle Linux
    ,
    Ubuntu
    , Archlinux,
    Fedora
    ,
    OpenSuSE
    ,
    SLES
    ,
    SLED
This module has been deprecated by its author since Jan 7th 2021.

The author has suggested puppet-nomad as its replacement.

Start using this module

Documentation

dudemcbacon/nomad — version 0.0.3 Apr 15th 2016

puppet-nomad

What This Module Affects

  • Installs the nomad daemon (via url or package)
    • If installing from zip, you must ensure the unzip utility is available.
  • Optionally installs a user to run it under
  • Installs a configuration file (/etc/nomad/config.json)
  • Manages the nomad service via upstart, sysv, or systemd

Usage

To set up a single nomad server, with several agents attached: On the server:

class { '::nomad':
	config_hash = {
    'region'     => 'us-west',
    'datacenter' => 'ptk',
    'log_level'  => 'INFO',
    'bind_addr'  => '0.0.0.0',
    'data_dir'   => '/opt/nomad',
    'server'     => {
      'enabled'          => true,
      'bootstrap_expect' => 3,
    }
  }
}

On the agent(s):

class { 'nomad':
  config_hash   => {
    'region'     => 'us-west',
    'datacenter' => 'ptk',
    'log_level'  => 'INFO',
    'bind_addr'  => '0.0.0.0',
    'data_dir'   => '/opt/nomad',
    'client'     => {
      'enabled'    => true,
      'servers'    => [
        "nomad01.your-org.pvt:4647",
        "nomad02.your-org.pvt:4647",
        "nomad03.your-org.pvt:4647"
      ]
    }
  },
}

Disable install and service components:

class { '::nomad':
  install_method => 'none',
  init_style     => false,
  manage_service => false,
  config_hash   => {
    'region'     => 'us-west',
    'datacenter' => 'ptk',
    'log_level'  => 'INFO',
    'bind_addr'  => '0.0.0.0',
    'data_dir'   => '/opt/nomad',
    'client'     => {
      'enabled'    => true,
      'servers'    => [
        "nomad01.your-org.pvt:4647",
        "nomad02.your-org.pvt:4647",
        "nomad03.your-org.pvt:4647"
      ]
    }
  },
}

Limitations

Depends on the JSON gem, or a modern ruby. (Ruby 1.8.7 is not officially supported)

Development

Open an issue or fork and open a Pull Request

Acknowledgement

Must of this module was refactored from Kyle Anderson's great consul module available on the puppet forge. Go give him stars and likes and what not -- he deserves them!