From 924b18d7469204ceaae60d7345712ea09f75a674 Mon Sep 17 00:00:00 2001 From: Instrumental Date: Thu, 5 Apr 2018 20:17:18 -0500 Subject: Add Certs, Docker Build Issue-ID: AAF-211 Change-Id: Idc7630578155586a6e53d7af80dd16e4e0ac41ca Signed-off-by: Instrumental --- auth/auth-certman/pom.xml | 3 ++- .../src/main/java/org/onap/aaf/auth/cm/AAF_CM.java | 17 +++-------------- 2 files changed, 5 insertions(+), 15 deletions(-) (limited to 'auth/auth-certman') diff --git a/auth/auth-certman/pom.xml b/auth/auth-certman/pom.xml index cfd08ce5..5b385014 100644 --- a/auth/auth-certman/pom.xml +++ b/auth/auth-certman/pom.xml @@ -99,7 +99,8 @@ org.onap.aaf.auth.cm.AAF_CM cm - cadi_prop_files=${project.conf_dir}/org.osaaf.cm.props + cadi_prop_files=${project.ext_root_dir}/etc/org.osaaf.cm.props + cadi_log_dir=${project.ext_root_dir}/logs/cm diff --git a/auth/auth-certman/src/main/java/org/onap/aaf/auth/cm/AAF_CM.java b/auth/auth-certman/src/main/java/org/onap/aaf/auth/cm/AAF_CM.java index aee48870..5c5ab962 100644 --- a/auth/auth-certman/src/main/java/org/onap/aaf/auth/cm/AAF_CM.java +++ b/auth/auth-certman/src/main/java/org/onap/aaf/auth/cm/AAF_CM.java @@ -22,7 +22,6 @@ package org.onap.aaf.auth.cm; -import java.io.File; import java.lang.reflect.Constructor; import java.util.Map; import java.util.Map.Entry; @@ -52,10 +51,10 @@ import org.onap.aaf.auth.server.AbsService; import org.onap.aaf.auth.server.JettyServiceStarter; import org.onap.aaf.auth.server.Log4JLogIt; import org.onap.aaf.cadi.Access; +import org.onap.aaf.cadi.Access.Level; import org.onap.aaf.cadi.CadiException; import org.onap.aaf.cadi.LocatorException; import org.onap.aaf.cadi.PropAccess; -import org.onap.aaf.cadi.Access.Level; import org.onap.aaf.cadi.aaf.v2_0.AAFAuthn; import org.onap.aaf.cadi.aaf.v2_0.AAFLurPerm; import org.onap.aaf.cadi.aaf.v2_0.AAFTrustChecker; @@ -229,19 +228,9 @@ public class AAF_CM extends AbsService { public static void main(final String[] args) { try { - String propsFile = getArg(AAF_LOG4J_PREFIX, args, "org.osaaf")+".log4j.props"; - String log_dir = getArg(Config.CADI_LOGDIR,args,"./logs"); - String log_level = getArg(Config.CADI_LOGLEVEL,args,"INFO"); - File logs = new File(log_dir); - if(!logs.isDirectory()) { - logs.delete(); - } - if(!logs.exists()) { - logs.mkdirs(); - } - Log4JLogIt logIt = new Log4JLogIt(log_dir,log_level,propsFile, "cm"); + Log4JLogIt logIt = new Log4JLogIt(args, "cm"); PropAccess propAccess = new PropAccess(logIt,args); - + AAF_CM service = new AAF_CM(new AuthzEnv(propAccess)); JettyServiceStarter jss = new JettyServiceStarter(service); jss.start(); -- cgit 1.2.3-korg