testsuite: Use SCRIPT_PATH
This commit is contained in:
parent
7a2bde57ff
commit
28d24ed8c6
@ -8,25 +8,26 @@ HBASE_DIR="hbase-${HBASE_VERSION}-hadoop2"
|
||||
#HBASE_URL="https://downloads.apache.org/hbase/${HBASE_VERSION}/${HBASE_FILE}"
|
||||
HBASE_URL="https://archive.apache.org/dist/hbase/hbase-${HBASE_VERSION}/${HBASE_FILE}"
|
||||
HBASE_FILE_CKSUM="1625453f839f7d8c86078a131af9731f6df28c59e58870db84913dcbc640d430253134a825de7cec247ea1f0cf232435765e00844ee2e4faf31aeb356955c478"
|
||||
HBASE_CONFIG_FILE="hbase/conf/hbase-site.xml"
|
||||
HBASE_CONFIG_TEMPLATE="hbase/conf/hbase-site.xml.j2"
|
||||
HBASE_TEST_SUITE_EXECUTABLE="hbase/bin/hbase"
|
||||
|
||||
declare -a DEPS=("java")
|
||||
|
||||
source setup.sh
|
||||
SCRIPT_PATH=$(dirname "$0")
|
||||
source $SCRIPT_PATH/setup.sh
|
||||
|
||||
create_hbase_config() {
|
||||
create_hbase_config_template() {
|
||||
read -r -d '' CONFIG <<EOF
|
||||
<?xml version="1.0"?>
|
||||
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
|
||||
<configuration>
|
||||
<property>
|
||||
<name>hbase.rootdir</name>
|
||||
<value>file:///${1}/hbase</value>
|
||||
<value>file:///{{ hbase_rootdir }}/hbase</value>
|
||||
</property>
|
||||
<property>
|
||||
<name>hbase.zookeeper.property.dataDir</name>
|
||||
<value>${1}/zookeeper</value>
|
||||
<value>{{ hbase_datadir }}/zookeeper</value>
|
||||
</property>
|
||||
<property>
|
||||
<name>hbase.unsafe.stream.capability.enforce</name>
|
||||
@ -63,6 +64,6 @@ prepare_hbase() {
|
||||
}
|
||||
|
||||
check_dependencies
|
||||
prepare_hbase ${HBASE_URL}
|
||||
HBASE_CONFIG=$(create_hbase_config "/tmp")
|
||||
write_file ${HBASE_CONFIG_FILE} "${HBASE_CONFIG}"
|
||||
#prepare_hbase ${HBASE_URL}
|
||||
HBASE_CONFIG=$(create_hbase_config_template)
|
||||
write_file ${HBASE_CONFIG_TEMPLATE} "${HBASE_CONFIG}"
|
||||
|
@ -6,13 +6,14 @@ HADOOP_VERSION="2.10.1"
|
||||
HADOOP_FILE="hadoop-$HADOOP_VERSION.tar.gz"
|
||||
HADOOP_URL="https://artfiles.org/apache.org/hadoop/common/hadoop-${HADOOP_VERSION}/${HADOOP_FILE}"
|
||||
HADOOP_FILE_CKSUM="2460e02cd1f80dfed7a8981bbc934c095c0a341435118bec781fd835ec2ebdc5543a03d92d24f2ddeebdfe1c2c460065ba1d394ed9a73cbb2020b40a8d8b5e07"
|
||||
HDFS_CONFIG_TEMPLATE="hadoop/etc/hadoop/hdfs-site.xml"
|
||||
HDFS_CONFIG_TEMPLATE_CORE="hadoop/etc/hadoop/core-site.xml"
|
||||
HDFS_CONFIG_TEMPLATE_MAPRED="hadoop/etc/hadoop/mapred-site.xml"
|
||||
HDFS_CONFIG_TEMPLATE="hadoop/etc/hadoop/hdfs-site.xml.j2"
|
||||
HDFS_CONFIG_TEMPLATE_CORE="hadoop/etc/hadoop/core-site.xml.j2"
|
||||
HDFS_CONFIG_TEMPLATE_MAPRED="hadoop/etc/hadoop/mapred-site.xml.j2"
|
||||
HDFS_CONFIG_DATANODES="localhost"
|
||||
HDFS_TEST_SUITE_EXECUTABLE="hadoop/bin/hdfs"
|
||||
|
||||
source setup.sh
|
||||
SCRIPT_PATH=$(dirname "$0")
|
||||
source $SCRIPT_PATH/setup.sh
|
||||
|
||||
declare -a DEPS=("java" "ansible-playbook")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user