bigtop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From asan...@apache.org
Subject [1/2] bigtop git commit: BIGTOP-2614- create bigtop/slaves docker image or fedora 25
Date Fri, 02 Dec 2016 18:09:18 GMT
Repository: bigtop
Updated Branches:
  refs/heads/master 32dbc7c3e -> 56deaa7c0


BIGTOP-2614- create bigtop/slaves docker image or fedora 25

Signed-off-by: Amir Sanjar <afsanjar@gmail.com>


Project: http://git-wip-us.apache.org/repos/asf/bigtop/repo
Commit: http://git-wip-us.apache.org/repos/asf/bigtop/commit/119d6665
Tree: http://git-wip-us.apache.org/repos/asf/bigtop/tree/119d6665
Diff: http://git-wip-us.apache.org/repos/asf/bigtop/diff/119d6665

Branch: refs/heads/master
Commit: 119d6665650336417241dfa5401d4d7f8b9fe7b8
Parents: 32dbc7c
Author: amir sanjar <afsanjar@gmail.com>
Authored: Thu Dec 1 13:43:29 2016 -0600
Committer: Amir Sanjar <afsanjar@gmail.com>
Committed: Thu Dec 1 23:06:10 2016 -0600

----------------------------------------------------------------------
 bigtop_toolchain/manifests/env.pp               | 13 ++++++++----
 bigtop_toolchain/manifests/jdk.pp               |  8 +++++--
 bigtop_toolchain/manifests/protobuf.pp          | 12 ++++++++++-
 bigtop_toolchain/manifests/user.pp              |  4 ++--
 .../bigtop-slaves/fedora-25-ppc64le/Dockerfile  | 22 ++++++++++++++++++++
 docker/bigtop-slaves/fedora-25/Dockerfile       | 22 ++++++++++++++++++++
 6 files changed, 72 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/bigtop/blob/119d6665/bigtop_toolchain/manifests/env.pp
----------------------------------------------------------------------
diff --git a/bigtop_toolchain/manifests/env.pp b/bigtop_toolchain/manifests/env.pp
index 03d1b03..68cfe42 100644
--- a/bigtop_toolchain/manifests/env.pp
+++ b/bigtop_toolchain/manifests/env.pp
@@ -14,9 +14,11 @@
 # limitations under the License.
 
 class bigtop_toolchain::env {
-  $java_version = '1.7.0'
+  case "$::operatingsystem $::operatingsystemrelease" {
+    /(Fedora) 25/: { $java_version = '1.8.0' }
+    default: { $java_version = '1.7.0' }
+    }
   $java = "java-${java_version}"
-
   case $architecture {
     'amd64' : { $arch= "amd64" }
     'ppc64le' : { $arch= "ppc64el" }
@@ -27,7 +29,10 @@ class bigtop_toolchain::env {
       $javahome = "/usr/lib/jvm/${java}-openjdk-$arch"
     }
     'Fedora','Centos', 'Amazon': {
-      $javahome = "/usr/lib/jvm/${java}"
+      case $architecture {
+         'amd64' : { $javahome = "/usr/lib/jvm/${java}" }
+         'ppc64le' : { $javahome = "/usr/lib/jvm/${java}-openjdk" }
+       }
     }
     'OpenSuSE' : {
       $javahome = "/usr/lib64/jvm/${java}-openjdk-${java_version}"
@@ -38,7 +43,7 @@ class bigtop_toolchain::env {
     ensure => present,
     owner  => root,
     group  => root,
-    mode   => 644,
+    mode   => "644",
   }
 }
 

http://git-wip-us.apache.org/repos/asf/bigtop/blob/119d6665/bigtop_toolchain/manifests/jdk.pp
----------------------------------------------------------------------
diff --git a/bigtop_toolchain/manifests/jdk.pp b/bigtop_toolchain/manifests/jdk.pp
index 730728f..06090ad 100644
--- a/bigtop_toolchain/manifests/jdk.pp
+++ b/bigtop_toolchain/manifests/jdk.pp
@@ -14,8 +14,12 @@
 # limitations under the License.
 
 class bigtop_toolchain::jdk {
-
-  case $operatingsystem{
+  case "$::operatingsystem $::operatingsystemrelease" {
+    /(Fedora) 25/: {
+       package { 'java-1.8.0-openjdk-devel' :
+       ensure => present
+      }
+    }
     Debian: {
       include apt
       include apt::backports

http://git-wip-us.apache.org/repos/asf/bigtop/blob/119d6665/bigtop_toolchain/manifests/protobuf.pp
----------------------------------------------------------------------
diff --git a/bigtop_toolchain/manifests/protobuf.pp b/bigtop_toolchain/manifests/protobuf.pp
index eed426e..58f010c 100644
--- a/bigtop_toolchain/manifests/protobuf.pp
+++ b/bigtop_toolchain/manifests/protobuf.pp
@@ -48,7 +48,15 @@ class bigtop_toolchain::protobuf {
     default: {
       case $operatingsystem {
          /(?i:(centos|fedora|amazon))/: {
-           yumrepo { "protobuf":
+          case $architecture {
+           'ppc64le' : { 
+            exec { 'install_mrdocs_repo':
+              command => "/usr/bin/rpm -ivh https://dl.fedoraproject.org/pub/fedora-secondary/releases/22/Everything/ppc64le/os/Packages/p/protobuf-2.5.0-11.fc22.ppc64le.rpm;/usr/bin/rpm
-ivh https://dl.fedoraproject.org/pub/fedora-secondary/releases/22/Everything/ppc64le/os/Packages/p/protobuf-compiler-2.5.0-11.fc22.ppc64le.rpm;/usr/bin/rpm
-ivh https://dl.fedoraproject.org/pub/fedora-secondary/releases/22/Everything/ppc64le/os/Packages/p/protobuf-devel-2.5.0-11.fc22.ppc64le.rpm",
+            }
+            $package_name = 'protobuf-devel'
+           }
+             
+           default: { yumrepo { "protobuf":
              baseurl => "http://download.opensuse.org/repositories/home:/mrdocs:/protobuf-rpm/CentOS_CentOS-6/",
              descr => "Bigtop protobuf repo",
              enabled => 1,
@@ -60,6 +68,8 @@ class bigtop_toolchain::protobuf {
              require => Yumrepo['protobuf'],
            }
            $package_name = 'protobuf-devel'
+           }
+          }
          }
          /(?i:(SLES|opensuse))/:{
            exec { 'install_mrdocs_repo':

http://git-wip-us.apache.org/repos/asf/bigtop/blob/119d6665/bigtop_toolchain/manifests/user.pp
----------------------------------------------------------------------
diff --git a/bigtop_toolchain/manifests/user.pp b/bigtop_toolchain/manifests/user.pp
index d231b27..901483e 100644
--- a/bigtop_toolchain/manifests/user.pp
+++ b/bigtop_toolchain/manifests/user.pp
@@ -33,7 +33,7 @@ class bigtop_toolchain::user {
     ensure => directory,
     owner => 'jenkins',
     group => 'jenkins',
-    mode => 755,
+    mode => "755",
     require => User['jenkins'],
   }
 
@@ -41,7 +41,7 @@ class bigtop_toolchain::user {
     ensure => directory,
     owner => 'jenkins',
     group => 'jenkins',
-    mode => 600,
+    mode => "600",
     require => User['jenkins'],
   }
 }

http://git-wip-us.apache.org/repos/asf/bigtop/blob/119d6665/docker/bigtop-slaves/fedora-25-ppc64le/Dockerfile
----------------------------------------------------------------------
diff --git a/docker/bigtop-slaves/fedora-25-ppc64le/Dockerfile b/docker/bigtop-slaves/fedora-25-ppc64le/Dockerfile
new file mode 100644
index 0000000..d799714
--- /dev/null
+++ b/docker/bigtop-slaves/fedora-25-ppc64le/Dockerfile
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+FROM bigtop/puppet:fedora-25-ppc64le
+MAINTAINER Amir Sanjar
+
+COPY bigtop_toolchain /etc/puppet/modules/bigtop_toolchain
+
+RUN puppet apply -e "include bigtop_toolchain::installer"
+COPY . /tmp/bigtop
+RUN cd /tmp/bigtop && ./gradlew && cd && rm -rf /tmp/bigtop

http://git-wip-us.apache.org/repos/asf/bigtop/blob/119d6665/docker/bigtop-slaves/fedora-25/Dockerfile
----------------------------------------------------------------------
diff --git a/docker/bigtop-slaves/fedora-25/Dockerfile b/docker/bigtop-slaves/fedora-25/Dockerfile
new file mode 100644
index 0000000..e820efb
--- /dev/null
+++ b/docker/bigtop-slaves/fedora-25/Dockerfile
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+FROM bigtop/puppet:fedora-25
+MAINTAINER Amir Sanjar
+
+COPY bigtop_toolchain /etc/puppet/modules/bigtop_toolchain
+
+RUN puppet apply -e "include bigtop_toolchain::installer"
+COPY . /tmp/bigtop
+RUN cd /tmp/bigtop && ./gradlew && cd && rm -rf /tmp/bigtop


Mime
View raw message