You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ranger.apache.org by rm...@apache.org on 2014/08/20 03:23:59 UTC
[1/3] git commit: ARGUS-11 Agent Installation script fails to create
credential store
Repository: incubator-argus
Updated Branches:
refs/heads/master 67f8a000d -> 72054a366
ARGUS-11 Agent Installation script fails to create credential store
Project: http://git-wip-us.apache.org/repos/asf/incubator-argus/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-argus/commit/0166486f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-argus/tree/0166486f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-argus/diff/0166486f
Branch: refs/heads/master
Commit: 0166486f36b56a8e8e34fc8161330b69999632b1
Parents: 086831e
Author: rmani <rm...@hortonworks.com>
Authored: Tue Aug 19 13:58:20 2014 -0700
Committer: rmani <rm...@hortonworks.com>
Committed: Tue Aug 19 13:58:20 2014 -0700
----------------------------------------------------------------------
hbase-agent/scripts/install.properties | 2 +-
hbase-agent/scripts/install.sh | 30 +++++++++++++++++++++++------
hdfs-agent/scripts/install.properties | 2 +-
hdfs-agent/scripts/install.sh | 25 ++++++++++++++++++++----
hive-agent/scripts/install.properties | 2 +-
hive-agent/scripts/install.sh | 25 ++++++++++++++++++++----
6 files changed, 69 insertions(+), 17 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/0166486f/hbase-agent/scripts/install.properties
----------------------------------------------------------------------
diff --git a/hbase-agent/scripts/install.properties b/hbase-agent/scripts/install.properties
index 064e2f4..42cc0ee 100644
--- a/hbase-agent/scripts/install.properties
+++ b/hbase-agent/scripts/install.properties
@@ -42,7 +42,7 @@ XAAUDIT.DB.PASSWORD=
#
# Credential Provider File Path
#
-# CREDENTIAL_PROVIDER_FILE=/etc/xasecure/conf/{repoName}-credstore.jceks
+# CREDENTIAL_PROVIDER_FILE=/etc/xasecure/{repoName}-credstore.jceks
#
CREDENTIAL_PROVIDER_FILE=
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/0166486f/hbase-agent/scripts/install.sh
----------------------------------------------------------------------
diff --git a/hbase-agent/scripts/install.sh b/hbase-agent/scripts/install.sh
index 5d1a371..cc34922 100644
--- a/hbase-agent/scripts/install.sh
+++ b/hbase-agent/scripts/install.sh
@@ -8,14 +8,14 @@ alias=$1
pass=$2
jceksFile=$3
-ret=`hadoop credential create ${alias} --value ${pass} --provider jceks://file${jceksFile} 2>&1`
+ret=`hadoop credential create ${alias} -value ${pass} -provider jceks://file${jceksFile} 2>&1`
res=`echo $ret | grep 'already exist'`
if ! [ "${res}" == "" ]
then
echo "Credential file already exists,recreating the file..."
- hadoop credential delete ${alias} --provider jceks://file${jceksFile}
- hadoop credential create ${alias} --value ${pass} --provider jceks://file${jceksFile}
+ hadoop credential delete ${alias} -provider jceks://file${jceksFile}
+ hadoop credential create ${alias} -value ${pass} -provider jceks://file${jceksFile}
fi
}
@@ -160,20 +160,38 @@ then
mv ${hbase_lib_dir}/${fn} ${hbase_lib_dir}/.${fn}.${cdt}
fi
echo "+cp ${f} ${hbase_lib_dir}/${fn}"
- cp ${f} ${hbase_lib_dir}/${fn}
+ cp ${f} ${hbase_lib_dir}/${fn}
fi
done
fi
CredFile=`grep '^CREDENTIAL_PROVIDER_FILE' ${install_dir}/install.properties | awk -F= '{ print $2 }'`
-
+
if ! [ `echo ${CredFile} | grep '^/.*'` ]
then
- echo "Please enter the Credential File Store with proper file path"
+ echo "ERROR:Please enter the Credential File Store with proper file path"
exit 1
fi
+dirno=`echo ${CredFile}| awk -F"/" '{ print NF}'`
+
+if [ ${dirno} -gt 2 ];
+then
+ pardir=`echo ${CredFile} | awk -F'/[^/]*$' '{ print $1 }'`
+ if [ ! -d ${pardir} ];
+ then
+ mkdir -p ${pardir}
+ if [ $? -eq 0 ];
+ then
+ chmod go+rx ${pardir}
+ else
+ echo "ERROR: Unable to create credential store file path"
+ fi
+ fi
+fi
+
+
#
# Generate Credential Provider file and Credential for Audit DB access.
#
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/0166486f/hdfs-agent/scripts/install.properties
----------------------------------------------------------------------
diff --git a/hdfs-agent/scripts/install.properties b/hdfs-agent/scripts/install.properties
index e851391..b622abe 100644
--- a/hdfs-agent/scripts/install.properties
+++ b/hdfs-agent/scripts/install.properties
@@ -44,7 +44,7 @@ XAAUDIT.DB.PASSWORD=
#
# Credential Provider File Path
#
-# CREDENTIAL_PROVIDER_FILE=/etc/xasecure/conf/{repoName}-credstore.jceks
+# CREDENTIAL_PROVIDER_FILE=/etc/xasecure/{repoName}-credstore.jceks
#
CREDENTIAL_PROVIDER_FILE=
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/0166486f/hdfs-agent/scripts/install.sh
----------------------------------------------------------------------
diff --git a/hdfs-agent/scripts/install.sh b/hdfs-agent/scripts/install.sh
index 59c248f..e8649c5 100644
--- a/hdfs-agent/scripts/install.sh
+++ b/hdfs-agent/scripts/install.sh
@@ -7,14 +7,14 @@ alias=$1
pass=$2
jceksFile=$3
-ret=`hadoop credential create ${alias} --value ${pass} --provider jceks://file${jceksFile} 2>&1`
+ret=`hadoop credential create ${alias} -value ${pass} -provider jceks://file${jceksFile} 2>&1`
res=`echo $ret | grep 'already exist'`
if ! [ "${res}" == "" ]
then
echo "Credential file already exists,recreating the file..."
- hadoop credential delete ${alias} --provider jceks://file${jceksFile}
- hadoop credential create ${alias} --value ${pass} --provider jceks://file${jceksFile}
+ hadoop credential delete ${alias} -provider jceks://file${jceksFile}
+ hadoop credential create ${alias} -value ${pass} -provider jceks://file${jceksFile}
fi
}
@@ -178,10 +178,27 @@ CredFile=`grep '^CREDENTIAL_PROVIDER_FILE' ${install_dir}/install.properties | a
if ! [ `echo ${CredFile} | grep '^/.*'` ]
then
- echo "Please enter the Credential File Store with proper file path"
+ echo "ERROR:Please enter the Credential File Store with proper file path"
exit 1
fi
+dirno=`echo ${CredFile}| awk -F"/" '{ print NF}'`
+
+if [ ${dirno} -gt 2 ];
+then
+ pardir=`echo ${CredFile} | awk -F'/[^/]*$' '{ print $1 }'`
+ if [ ! -d ${pardir} ];
+ then
+ mkdir -p ${pardir}
+ if [ $? -eq 0 ];
+ then
+ chmod go+rx ${pardir}
+ else
+ echo "ERROR: Unable to create credential store file path"
+ fi
+ fi
+fi
+
#
# Generate Credential Provider file and Credential for Audit DB access.
#
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/0166486f/hive-agent/scripts/install.properties
----------------------------------------------------------------------
diff --git a/hive-agent/scripts/install.properties b/hive-agent/scripts/install.properties
index 9ce44be..6d26ec3 100644
--- a/hive-agent/scripts/install.properties
+++ b/hive-agent/scripts/install.properties
@@ -49,7 +49,7 @@ POLICY_CACHE_FILE_PATH=
#
# Credential Provider File Path
#
-# CREDENTIAL_PROVIDER_FILE=/etc/xasecure/conf/{repoName}-credstore.jceks
+# CREDENTIAL_PROVIDER_FILE=/etc/xasecure/{repoName}-credstore.jceks
#
CREDENTIAL_PROVIDER_FILE=
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/0166486f/hive-agent/scripts/install.sh
----------------------------------------------------------------------
diff --git a/hive-agent/scripts/install.sh b/hive-agent/scripts/install.sh
index 51e49a0..7f59e37 100644
--- a/hive-agent/scripts/install.sh
+++ b/hive-agent/scripts/install.sh
@@ -7,14 +7,14 @@ alias=$1
pass=$2
jceksFile=$3
-ret=`hadoop credential create ${alias} --value ${pass} --provider jceks://file${jceksFile} 2>&1`
+ret=`hadoop credential create ${alias} -value ${pass} -provider jceks://file${jceksFile} 2>&1`
res=`echo $ret | grep 'already exist'`
if ! [ "${res}" == "" ]
then
echo "Credential file already exists,recreating the file..."
- hadoop credential delete ${alias} --provider jceks://file${jceksFile}
- hadoop credential create ${alias} --value ${pass} --provider jceks://file${jceksFile}
+ hadoop credential delete ${alias} -provider jceks://file${jceksFile}
+ hadoop credential create ${alias} -value ${pass} -provider jceks://file${jceksFile}
fi
}
@@ -146,10 +146,27 @@ CredFile=`grep '^CREDENTIAL_PROVIDER_FILE' ${install_dir}/install.properties | a
if ! [ `echo ${CredFile} | grep '^/.*'` ]
then
- echo "Please enter the Credential File Store with proper file path"
+ echo "ERROR:Please enter the Credential File Store with proper file path"
exit 1
fi
+dirno=`echo ${CredFile}| awk -F"/" '{ print NF}'`
+
+if [ ${dirno} -gt 2 ];
+then
+ pardir=`echo ${CredFile} | awk -F'/[^/]*$' '{ print $1 }'`
+ if [ ! -d ${pardir} ];
+ then
+ mkdir -p ${pardir}
+ if [ $? -eq 0 ];
+ then
+ chmod go+rx ${pardir}
+ else
+ echo "ERROR: Unable to create credential store file path"
+ fi
+ fi
+fi
+
#
# Generate Credential Provider file and Credential for Audit DB access.
#
[2/3] git commit: Argus11 - Credential Store creation issue fix
Posted by rm...@apache.org.
Argus11 - Credential Store creation issue fix
Project: http://git-wip-us.apache.org/repos/asf/incubator-argus/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-argus/commit/dfa698f2
Tree: http://git-wip-us.apache.org/repos/asf/incubator-argus/tree/dfa698f2
Diff: http://git-wip-us.apache.org/repos/asf/incubator-argus/diff/dfa698f2
Branch: refs/heads/master
Commit: dfa698f2ab2d3ab0e5aa0a0fd342f4f3c2fa6db4
Parents: 0166486
Author: rmani <rm...@hortonworks.com>
Authored: Tue Aug 19 15:23:10 2014 -0700
Committer: rmani <rm...@hortonworks.com>
Committed: Tue Aug 19 15:23:10 2014 -0700
----------------------------------------------------------------------
hbase-agent/conf/xasecure-audit-changes.cfg | 4 ++--
hdfs-agent/conf/xasecure-audit-changes.cfg | 2 +-
hive-agent/conf/xasecure-audit-changes.cfg | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/dfa698f2/hbase-agent/conf/xasecure-audit-changes.cfg
----------------------------------------------------------------------
diff --git a/hbase-agent/conf/xasecure-audit-changes.cfg b/hbase-agent/conf/xasecure-audit-changes.cfg
index 4b04f92..e3d05f0 100644
--- a/hbase-agent/conf/xasecure-audit-changes.cfg
+++ b/hbase-agent/conf/xasecure-audit-changes.cfg
@@ -1,5 +1,5 @@
xasecure.audit.jpa.javax.persistence.jdbc.url jdbc:mysql://%XAAUDIT.DB.HOSTNAME%/%XAAUDIT.DB.DATABASE_NAME% mod create-if-not-exists
xasecure.audit.jpa.javax.persistence.jdbc.user %XAAUDIT.DB.USER_NAME% mod create-if-not-exists
-xasecure.audit.jpa.javax.persistence.jdbc.password %XAAUDIT.DB.PASSWORD% mod create-if-not-exists
-xasecure.audit.repository.name %REPOSITORY_NAME% mod create-if-not-exists
+xasecure.audit.jpa.javax.persistence.jdbc.password crypted mod create-if-not-exists
+xasecure.audit.repository.name %REPOSITORY_NAME% mod create-if-not-exists
xasecure.audit.credential.provider.file jceks://file%CREDENTIAL_PROVIDER_FILE% mod create-if-not-exists
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/dfa698f2/hdfs-agent/conf/xasecure-audit-changes.cfg
----------------------------------------------------------------------
diff --git a/hdfs-agent/conf/xasecure-audit-changes.cfg b/hdfs-agent/conf/xasecure-audit-changes.cfg
index 4b04f92..dc873d5 100644
--- a/hdfs-agent/conf/xasecure-audit-changes.cfg
+++ b/hdfs-agent/conf/xasecure-audit-changes.cfg
@@ -1,5 +1,5 @@
xasecure.audit.jpa.javax.persistence.jdbc.url jdbc:mysql://%XAAUDIT.DB.HOSTNAME%/%XAAUDIT.DB.DATABASE_NAME% mod create-if-not-exists
xasecure.audit.jpa.javax.persistence.jdbc.user %XAAUDIT.DB.USER_NAME% mod create-if-not-exists
-xasecure.audit.jpa.javax.persistence.jdbc.password %XAAUDIT.DB.PASSWORD% mod create-if-not-exists
+xasecure.audit.jpa.javax.persistence.jdbc.password crypted mod create-if-not-exists
xasecure.audit.repository.name %REPOSITORY_NAME% mod create-if-not-exists
xasecure.audit.credential.provider.file jceks://file%CREDENTIAL_PROVIDER_FILE% mod create-if-not-exists
http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/dfa698f2/hive-agent/conf/xasecure-audit-changes.cfg
----------------------------------------------------------------------
diff --git a/hive-agent/conf/xasecure-audit-changes.cfg b/hive-agent/conf/xasecure-audit-changes.cfg
index 4b04f92..a8d053e 100644
--- a/hive-agent/conf/xasecure-audit-changes.cfg
+++ b/hive-agent/conf/xasecure-audit-changes.cfg
@@ -1,5 +1,5 @@
xasecure.audit.jpa.javax.persistence.jdbc.url jdbc:mysql://%XAAUDIT.DB.HOSTNAME%/%XAAUDIT.DB.DATABASE_NAME% mod create-if-not-exists
xasecure.audit.jpa.javax.persistence.jdbc.user %XAAUDIT.DB.USER_NAME% mod create-if-not-exists
-xasecure.audit.jpa.javax.persistence.jdbc.password %XAAUDIT.DB.PASSWORD% mod create-if-not-exists
+xasecure.audit.jpa.javax.persistence.jdbc.password crypted mod create-if-not-exists
xasecure.audit.repository.name %REPOSITORY_NAME% mod create-if-not-exists
xasecure.audit.credential.provider.file jceks://file%CREDENTIAL_PROVIDER_FILE% mod create-if-not-exists
[3/3] git commit: Merge branch 'master' of
https://github.com/apache/incubator-argus.git
Posted by rm...@apache.org.
Merge branch 'master' of https://github.com/apache/incubator-argus.git
Project: http://git-wip-us.apache.org/repos/asf/incubator-argus/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-argus/commit/72054a36
Tree: http://git-wip-us.apache.org/repos/asf/incubator-argus/tree/72054a36
Diff: http://git-wip-us.apache.org/repos/asf/incubator-argus/diff/72054a36
Branch: refs/heads/master
Commit: 72054a366e85b089df9937e55ded6b05a2e73ead
Parents: dfa698f 67f8a00
Author: rmani <rm...@hortonworks.com>
Authored: Tue Aug 19 18:20:25 2014 -0700
Committer: rmani <rm...@hortonworks.com>
Committed: Tue Aug 19 18:20:25 2014 -0700
----------------------------------------------------------------------
agents-audit/pom.xml | 2 +-
agents-common/pom.xml | 2 +-
agents-cred/pom.xml | 2 +-
agents-impl/pom.xml | 2 +-
agents-installer/pom.xml | 2 +-
credentialbuilder/pom.xml | 4 +-
embededwebserver/pom.xml | 4 +-
hbase-agent/pom.xml | 2 +-
hdfs-agent/pom.xml | 2 +-
hive-agent/pom.xml | 2 +-
knox-agent/pom.xml | 2 +-
lookup-client/pom.xml | 4 +-
pom.xml | 2 +-
security-admin/pom.xml | 4 +-
.../src/main/webapp/scripts/models/VXAsset.js | 2 +
.../src/main/webapp/scripts/utils/XAUtils.js | 14 ++-
.../webapp/scripts/views/asset/AssetForm.js | 9 +-
.../scripts/views/common/FormInputItemList.js | 88 ++++++++++--------
.../scripts/views/common/UserPermissionList.js | 95 +++++++++++---------
.../main/webapp/scripts/views/users/UserForm.js | 9 ++
.../src/main/webapp/styles/bootstrap.css | 4 +-
.../src/main/webapp/styles/bootstrap.min.css | 4 +-
security-admin/src/main/webapp/styles/xa.css | 2 +
.../webapp/templates/asset/AssetForm_tmpl.html | 1 +
.../templates/common/UserPermissionItem.html | 7 +-
.../webapp/templates/common/formInputItem.html | 14 +--
ugsync/pom.xml | 2 +-
unixauthclient/pom.xml | 2 +-
unixauthservice/pom.xml | 4 +-
29 files changed, 170 insertions(+), 123 deletions(-)
----------------------------------------------------------------------