You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bigtop.apache.org by ma...@apache.org on 2013/12/27 16:05:12 UTC

git commit: BIGTOP-1170. Add an easier tool for uploading / creating the sharelib

Updated Branches:
  refs/heads/master bd559f74f -> 715f0bf4f


BIGTOP-1170. Add an easier tool for uploading / creating the sharelib


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

Branch: refs/heads/master
Commit: 715f0bf4fdb519517c62bfd659e4401ad7278a11
Parents: bd559f7
Author: Sean Mackrory <ma...@apache.org>
Authored: Mon Dec 23 11:50:01 2013 -0700
Committer: Sean Mackrory <ma...@apache.org>
Committed: Fri Dec 27 08:02:42 2013 -0700

----------------------------------------------------------------------
 .../src/common/oozie/install_oozie.sh           | 33 +++++++++++++++++++-
 bigtop-packages/src/rpm/oozie/SPECS/oozie.spec  |  2 ++
 2 files changed, 34 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/bigtop/blob/715f0bf4/bigtop-packages/src/common/oozie/install_oozie.sh
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/common/oozie/install_oozie.sh b/bigtop-packages/src/common/oozie/install_oozie.sh
index c203163..efddce0 100755
--- a/bigtop-packages/src/common/oozie/install_oozie.sh
+++ b/bigtop-packages/src/common/oozie/install_oozie.sh
@@ -144,6 +144,37 @@ exec /usr/lib/oozie/bin/oozie "\$@"
 EOF
 chmod 755 ${BIN_DIR}/oozie
 
+[ -d ${SERVER_PREFIX}/usr/bin ] || install -d -m 0755 ${SERVER_PREFIX}/usr/bin
+cat > ${SERVER_PREFIX}/usr/bin/oozie-setup <<'EOF'
+#!/bin/bash
+#
+# 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.
+
+# Autodetect JAVA_HOME if not defined
+. /usr/lib/bigtop-utils/bigtop-detect-javahome
+
+if [ "$1" == "prepare-war" ]; then
+    echo "The prepare-war command is not supported in Apache Bigtop packages."
+    exit 1
+fi
+
+COMMAND="/usr/lib/oozie/bin/oozie-setup.sh $@"
+su -s /bin/bash -c "$COMMAND" oozie
+EOF
+chmod 755 ${SERVER_PREFIX}/usr/bin/oozie-setup
 
 ## Install server image
 SERVER_LIB_DIR=${SERVER_PREFIX}/usr/lib/oozie
@@ -154,7 +185,7 @@ DATA_DIR=${SERVER_PREFIX}/var/lib/oozie
 install -d -m 0755 ${SERVER_LIB_DIR}
 install -d -m 0755 ${SERVER_LIB_DIR}/bin
 install -d -m 0755 ${DATA_DIR}
-for file in ooziedb.sh oozied.sh oozie-sys.sh ; do
+for file in ooziedb.sh oozied.sh oozie-sys.sh oozie-setup.sh ; do
   cp ${BUILD_DIR}/bin/$file ${SERVER_LIB_DIR}/bin
 done
 

http://git-wip-us.apache.org/repos/asf/bigtop/blob/715f0bf4/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec b/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec
index 28bbedb..35e7824 100644
--- a/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec
+++ b/bigtop-packages/src/rpm/oozie/SPECS/oozie.spec
@@ -183,10 +183,12 @@ fi
 %defattr(-,root,root)
 %config(noreplace) %{conf_oozie_dist}
 %config(noreplace) %{tomcat_deployment_oozie}.*
+%{usr_bin}/oozie-setup
 %{lib_oozie}/bin/oozie-sys.sh
 %{lib_oozie}/bin/oozie-env.sh
 %{lib_oozie}/bin/oozied.sh
 %{lib_oozie}/bin/ooziedb.sh
+%{lib_oozie}/bin/oozie-setup.sh
 %{lib_oozie}/webapps
 %{lib_oozie}/libtools
 %{lib_oozie}/libserver