Puppet Class: python::pyenv

Defined in:
manifests/pyenv.pp

Overview

Manage python version with pyenv

Usage:

include python::pyenv

Normally internal use only; will automatically included by the ‘python` class

Parameters:

  • ensure (Any) (defaults to: $python::pyenv::ensure)
  • prefix (Any) (defaults to: $python::pyenv::prefix)
  • user (Any) (defaults to: $python::pyenv::user)


8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# File 'manifests/pyenv.pp', line 8

class python::pyenv(
  $ensure = $python::pyenv::ensure,
  $prefix = $python::pyenv::prefix,
  $user   = $python::pyenv::user,
) {
  require python

  repository { $prefix:
    ensure => $ensure,
    force  => true,
    source => 'yyuu/pyenv',
    user   => $user,
  }

  file { "${prefix}/versions":
    ensure  => symlink,
    force   => true,
    backup  => false,
    target  => '/opt/python',
    require => Repository[$prefix],
  }
}