EOX GitLab Instance

init.pp 1.31 KB
Newer Older
1
class buildtools {
2
3
4
5
    class { 'repos':
        # add to the repositories stage
        stage   => repositories
    }
6

7
    $home = '/home/vagrant'
8

9
10
11
12
13
    File {
        owner => 'vagrant',
        group => 'vagrant',
        mode  => '0644',
    }
14

15
    package { 'rpm-build': ensure => 'latest' }
Stephan Meißl's avatar
Stephan Meißl committed
16
    package { 'rpmdevtools': ensure => 'latest' }
17
18
19
20
21
22
    package { 'yum-utils': ensure => 'latest' }
    package { 'mock': ensure => 'latest' }
    package { 'redhat-rpm-config': ensure => 'latest' }
    package { 'make': ensure => 'latest' }
    package { 'gcc': ensure => 'latest' }
    package { 'gcc-c++': ensure => 'latest' }
23

24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
    file { $home: ensure => directory }
    file { "${home}/.rpmmacros":
        ensure  => file,
        content => "%_topdir ${home}/rpmbuild\n%__os_install_post %{nil}\n",
    }
    file { "${home}/rpmbuild":
        ensure  => directory,
    }
    file {[ "${home}/rpmbuild/BUILD",
            "${home}/rpmbuild/BUILDROOT",
            "${home}/rpmbuild/RPMS",
            "${home}/rpmbuild/SOURCES",
            "${home}/rpmbuild/SPECS",
            "${home}/rpmbuild/SRPMS" ]:
        ensure  => directory,
        mode    => '0775'
    }

    file { "${home}/.pypirc":
        ensure  => file,
        content => "[distutils]\nindex-servers =\n    pypi\n\n[pypi]\nusername:<USER>\npassword:<PW>\n",
    }
}