aboutsummaryrefslogtreecommitdiffstats
path: root/manifests/install.pp
blob: 7a3059478ff855f7f5d2b2657280a3d6f5061745 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# == Class fdio::install
#
# Manages the installation of fdio.
#
class fdio::install {

  if !empty($fdio::repo_branch) and $fdio::repo_branch != 'none' {
    $base_url = $fdio::repo_branch ? {
      'release' => 'https://nexus.fd.io/content/repositories/fd.io.centos7/',
      'master'  => 'https://nexus.fd.io/content/repositories/fd.io.master.centos7/',
      default   => "https://nexus.fd.io/content/repositories/fd.io.${fdio::repo_branch}.centos7/",
    }

    # Add fdio's Yum repository
    yumrepo { "fdio-${fdio::repo_branch}":
      baseurl  => $base_url,
      descr    => "FD.io ${fdio::repo_branch} packages",
      enabled  => 1,
      gpgcheck => 0,
      notify   => Package['vpp'],
    }
  }

  # Install the VPP RPM
  package { 'vpp':
    ensure => present,
  }


  if $fdio::vpp_dpdk_support {
    package { 'vpp-plugins':
      ensure  => present,
      require => Package['vpp'],
    }
  }
}