Giter Club home page Giter Club logo

puppet-portage's Introduction

Puppet Gentoo Portage Module

Provides Gentoo Portage features for Puppet.

Travis Test status: Build Status

/etc/portage/package.*/*

package_use

package_use { 'app-admin/puppet':
  use     => ['flag1', 'flag2'],
  target  => 'puppet-flags',
  version => '>=3.0.1',
  ensure  => present,
}

use can be either a string or an array of strings.

package_keywords

package_keywords { 'app-admin/puppet':
  keywords => ['~x86', '-hppa'],
  target   => 'puppet',
  version  => '>=3.0.1',
  ensure   => present,
}

keywords can be either a string or an array of strings.

package_unmask

package_unmask { 'app-admin/puppet':
  target  => 'puppet',
  version => '>=3.0.1',
  ensure  => present,
}

package_mask

package_mask { 'app-admin/puppet':
  target  => 'tree',
  version => '>=3.0.1',
  ensure  => present,
}

package_env

package_env { 'www-client/firefox':
  env     => 'no-lto',
  target  => 'firefox',
  version => '>=20.0',
  ensure  => present,
}

env can be either a string or an array of strings.

make.conf

The default location of make.conf is /etc/portage/make.conf If you want to change it, you should do the following:

class { 'portage':
  make_conf = '/etc/make.conf',
}

In order to add entries to make.conf:

portage::makeconf { 'portdir_overlay':
  content => '/var/lib/layman',
  ensure  => present,
}
portage::makeconf { 'use':
  content => ['flag1', 'flag2'],
  ensure  => present,
}

Changes in the USE variable will also trigger re-emerge of the affected packages.

You can also specify special content:

portage::makeconf { 'source /var/lib/layman/make.conf': }

portage::package

This module provides a wrapper to the native package type:

portage::package { 'app-admin/puppet':
  use              => ['-minimal', 'augeas'],
  use_version      => '>=3.0.1',
  keywords         => ['~amd64', '~x86'],
  keywords_version => '>=3.0.1',
  mask_version     => '<=2.3.17',
  unmask_version   => '>=3.0.1',
  target           => 'puppet',
  keywords_target  => 'puppet-keywords',
  ensure           => '3.0.1',
}

If no {keywords,use,mask,unmask}\_target is specified, then the value of target is being used. The variables keywords, mask and unmask also accept the special value all, that will create versionless entries. (This applies only to portage::package, if you want versionless entries in any of the above package\_\* types, you can just omit the version attribute.) Any change in portage::package will also trigger the appropriate re-emerge to the affected package.

facts

All make.conf variables and most of the eselect modules are shown by facter

eselect

The eselect type/provider checks for the current state of an eselect module (or gcc-config) by reading the currently selected value.

eselect { 'ruby':
  set => 'ruby19',
}

Some eselect modules have special options or submodules:

eselect { 'python::python2':
  set => 'python2.7',
}

eselect { 'php::apache2':
  set => 'php5.3',
}

webapp

The webapp type/provider can be used to manage webapps via webapp-config.

webapp { 'www.example.org::/app':
  appname    => 'django',
  appversion => '1.4.5',
  server     => 'nginx',
  user       => 'nginx',
  group      => 'nginx',
  secure     => 'yes',
}

layman

The layman type/provider can be used to manage overlays via layman.

layman { 'x11':
  ensure => present,
}

Installation of Gentoo tools

This module can also handle the installation of various Gentoo tools.

class { 'portage':
  portage_ensure => '2.2.6',
  eix_ensure     => '0.29.4',
  eix_keywords   => ['~amd64', '~x86'],
}

See manifests/init.pp for all the available tools that can be defined. (It is recommended to use hiera in order to define the values)

See Also

Contributors

puppet-portage's People

Contributors

adrienthebo avatar vikraman avatar ramereth avatar tampakrap avatar thias avatar

Watchers

Spencer Tom Tafadzwa Chirume avatar James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.