Repository: bigtop Updated Branches: refs/heads/master 32c5e7c36 -> abd615cc6
BIGTOP-1676. Puppet: add deb repo auto deploy Project: http://git-wip-us.apache.org/repos/asf/bigtop/repo Commit: http://git-wip-us.apache.org/repos/asf/bigtop/commit/abd615cc Tree: http://git-wip-us.apache.org/repos/asf/bigtop/tree/abd615cc Diff: http://git-wip-us.apache.org/repos/asf/bigtop/diff/abd615cc Branch: refs/heads/master Commit: abd615cc6fc1750374412f0df16fe9954639897b Parents: 32c5e7c Author: Evans Ye <[email protected]> Authored: Tue Feb 17 16:51:44 2015 +0000 Committer: Evans Ye <[email protected]> Committed: Wed Feb 25 03:00:42 2015 +0000 ---------------------------------------------------------------------- .../puppet/hieradata/bigtop/cluster.yaml | 2 +- bigtop-deploy/puppet/manifests/cluster.pp | 3 ++- bigtop-deploy/puppet/manifests/site.pp | 19 +++++++++++++++---- bigtop-deploy/vm/utils/setup-env-debian.sh | 2 +- .../vagrantconfig_debian.yaml | 2 +- 5 files changed, 20 insertions(+), 8 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/bigtop/blob/abd615cc/bigtop-deploy/puppet/hieradata/bigtop/cluster.yaml ---------------------------------------------------------------------- diff --git a/bigtop-deploy/puppet/hieradata/bigtop/cluster.yaml b/bigtop-deploy/puppet/hieradata/bigtop/cluster.yaml index 3a73a97..c7b279e 100644 --- a/bigtop-deploy/puppet/hieradata/bigtop/cluster.yaml +++ b/bigtop-deploy/puppet/hieradata/bigtop/cluster.yaml @@ -31,7 +31,7 @@ # - /data/3 # - /data/4 -#bigtop::bigtop_yumrepo_uri: "http://mirror.example.com/path/to/mirror/" +#bigtop::bigtop_repo_uri: "http://mirror.example.com/path/to/mirror/" # Test-only variable controls if user hdfs' sshkeys should be installed to allow # for passwordless login across the cluster. Required by some integration tests http://git-wip-us.apache.org/repos/asf/bigtop/blob/abd615cc/bigtop-deploy/puppet/manifests/cluster.pp ---------------------------------------------------------------------- diff --git a/bigtop-deploy/puppet/manifests/cluster.pp b/bigtop-deploy/puppet/manifests/cluster.pp index cf88397..9f835d9 100644 --- a/bigtop-deploy/puppet/manifests/cluster.pp +++ b/bigtop-deploy/puppet/manifests/cluster.pp @@ -92,7 +92,8 @@ class hadoop_head_node inherits hadoop_worker_node { exec { "init hdfs": path => ['/bin','/sbin','/usr/bin','/usr/sbin'], command => 'bash -x /usr/lib/hadoop/libexec/init-hdfs.sh', - require => Package['hadoop-hdfs'] + require => Package['hadoop-hdfs'], + timeout => 0 } Class['Hadoop::Namenode'] -> Class['Hadoop::Datanode'] -> Exec<| title == "init hdfs" |> http://git-wip-us.apache.org/repos/asf/bigtop/blob/abd615cc/bigtop-deploy/puppet/manifests/site.pp ---------------------------------------------------------------------- diff --git a/bigtop-deploy/puppet/manifests/site.pp b/bigtop-deploy/puppet/manifests/site.pp index dd5921c..6570123 100644 --- a/bigtop-deploy/puppet/manifests/site.pp +++ b/bigtop-deploy/puppet/manifests/site.pp @@ -14,6 +14,7 @@ # limitations under the License. $default_yumrepo = "http://bigtop01.cloudera.org:8080/view/Releases/job/Bigtop-0.8.0/label=centos6/6/artifact/output/" +$default_debrepo = "http://bigtop01.cloudera.org:8080/view/Releases/job/Bigtop-0.8.0/label=trusty/5/artifact/output/apt/" $jdk_package_name = hiera("bigtop::jdk_package_name", "jdk") stage {"pre": before => Stage["main"]} @@ -21,14 +22,26 @@ stage {"pre": before => Stage["main"]} case $operatingsystem { /(OracleLinux|Amazon|CentOS|Fedora|RedHat)/: { yumrepo { "Bigtop": - baseurl => hiera("hiera::bigtop_yumrepo_uri", $default_yumrepo), + baseurl => hiera("hiera::bigtop_repo_uri", $default_yumrepo), descr => "Bigtop packages", enabled => 1, gpgcheck => 0, } + Yumrepo<||> -> Package<||> + } + /(Ubuntu|Debian)/: { + class { "apt": disable_keys => true } + apt::source { "Bigtop": + location => hiera("hiera::bigtop_repo_uri", $default_debrepo), + release => "bigtop", + repos => "contrib", + ensure => present, + include_src => false, + } + Apt::Source<||> -> Package<||> } default: { - notify{"WARNING: running on a non-yum platform -- make sure Bigtop repo is setup": } + notify{"WARNING: running on a neither yum nor apt platform -- make sure Bigtop repo is setup": } } } @@ -68,8 +81,6 @@ node default { } } -Yumrepo<||> -> Package<||> - if versioncmp($::puppetversion,'3.6.1') >= 0 { $allow_virtual_packages = hiera('bigtop::allow_virtual_packages',false) Package { http://git-wip-us.apache.org/repos/asf/bigtop/blob/abd615cc/bigtop-deploy/vm/utils/setup-env-debian.sh ---------------------------------------------------------------------- diff --git a/bigtop-deploy/vm/utils/setup-env-debian.sh b/bigtop-deploy/vm/utils/setup-env-debian.sh index 1f0d197..55483c4 100755 --- a/bigtop-deploy/vm/utils/setup-env-debian.sh +++ b/bigtop-deploy/vm/utils/setup-env-debian.sh @@ -17,7 +17,7 @@ apt-get update # Install puppet agent -apt-get -y install puppet puppet-module-puppetlabs-stdlib curl +apt-get -y install puppet puppet-module-puppetlabs-stdlib puppet-module-puppetlabs-apt curl mkdir -p /data/{1,2} http://git-wip-us.apache.org/repos/asf/bigtop/blob/abd615cc/bigtop-deploy/vm/vagrant-puppet-docker/vagrantconfig_debian.yaml ---------------------------------------------------------------------- diff --git a/bigtop-deploy/vm/vagrant-puppet-docker/vagrantconfig_debian.yaml b/bigtop-deploy/vm/vagrant-puppet-docker/vagrantconfig_debian.yaml index 5a8e772..3dc5a75 100644 --- a/bigtop-deploy/vm/vagrant-puppet-docker/vagrantconfig_debian.yaml +++ b/bigtop-deploy/vm/vagrant-puppet-docker/vagrantconfig_debian.yaml @@ -6,7 +6,7 @@ boot2docker: memory_size: "4196" number_cpus: "2" -repo: "http://to.do/notyet" +repo: "http://bigtop01.cloudera.org:8080/view/Releases/job/Bigtop-0.8.0/label=trusty/5/artifact/output/apt/" distro: debian components: [hadoop, yarn] namenode_ui_port: "50070"
