diff options
Diffstat (limited to 'plugins/grToolkit')
7 files changed, 27 insertions, 6 deletions
diff --git a/plugins/grToolkit/provider/pom.xml b/plugins/grToolkit/provider/pom.xml index 5c77331c0..b44436697 100755 --- a/plugins/grToolkit/provider/pom.xml +++ b/plugins/grToolkit/provider/pom.xml @@ -118,6 +118,26 @@ </instructions> </configuration> </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-surefire-plugin</artifactId> + <configuration> + <environmentVariables> + <ODL_USER>admin</ODL_USER> + <ODL_PASSWORD>admin</ODL_PASSWORD> + </environmentVariables> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-failsafe-plugin</artifactId> + <configuration> + <environmentVariables> + <ODL_USER>admin</ODL_USER> + <ODL_PASSWORD>admin</ODL_PASSWORD> + </environmentVariables> + </configuration> + </plugin> </plugins> </build> </project> diff --git a/plugins/grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java b/plugins/grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java index 5a8730bff..8da2f09ae 100755 --- a/plugins/grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java +++ b/plugins/grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java @@ -45,6 +45,7 @@ import org.apache.commons.lang.StringUtils; import org.json.JSONArray; import org.json.JSONObject; import org.onap.ccsdk.sli.core.dblib.DbLibService; +import org.onap.ccsdk.sli.core.utils.common.EnvProperties; import org.onap.ccsdk.sli.plugins.grtoolkit.connection.ConnectionManager; import org.onap.ccsdk.sli.plugins.grtoolkit.connection.ConnectionResponse; import org.onap.ccsdk.sli.plugins.grtoolkit.data.AdminHealth; @@ -183,7 +184,7 @@ public class GrToolkitProvider implements AutoCloseable, GrToolkitService, DataT */ private void setProperties() { log.info("Loading properties from {}", PROPERTIES_FILE); - properties = new Properties(); + properties = new EnvProperties(); File propertiesFile = new File(PROPERTIES_FILE); if(!propertiesFile.exists()) { log.warn("setProperties(): Properties file not found."); diff --git a/plugins/grToolkit/provider/src/main/resources/gr-toolkit.properties b/plugins/grToolkit/provider/src/main/resources/gr-toolkit.properties index e3463df08..bce40620e 100755 --- a/plugins/grToolkit/provider/src/main/resources/gr-toolkit.properties +++ b/plugins/grToolkit/provider/src/main/resources/gr-toolkit.properties @@ -24,7 +24,7 @@ adm.fqdn= adm.healthcheck=/healthcheck adm.port.http=8181 adm.port.ssl=8443 -controller.credentials=admin:admin +controller.credentials=${ODL_USER}:${ODL_PASSWORD} controller.useSsl=true controller.port.http=8181 controller.port.ssl=8443 diff --git a/plugins/grToolkit/provider/src/test/resources/gr-toolkit.properties b/plugins/grToolkit/provider/src/test/resources/gr-toolkit.properties index 52b19bf51..d3b15e70e 100755 --- a/plugins/grToolkit/provider/src/test/resources/gr-toolkit.properties +++ b/plugins/grToolkit/provider/src/test/resources/gr-toolkit.properties @@ -24,7 +24,7 @@ adm.fqdn=localhost adm.healthcheck=/adm/healthcheck adm.port.http=9999 adm.port.ssl=19999 -controller.credentials=admin:admin +controller.credentials=${ODL_USER}:${ODL_PASSWORD} controller.useSsl=false controller.port.http=9999 controller.port.ssl=19999 diff --git a/plugins/grToolkit/provider/src/test/resources/single/gr-toolkit.properties b/plugins/grToolkit/provider/src/test/resources/single/gr-toolkit.properties index cc7820e90..040f082df 100755 --- a/plugins/grToolkit/provider/src/test/resources/single/gr-toolkit.properties +++ b/plugins/grToolkit/provider/src/test/resources/single/gr-toolkit.properties @@ -23,7 +23,7 @@ adm.fqdn=localhost adm.healthcheck=/adm/healthcheck adm.port.http=9999 adm.port.ssl=19999 -controller.credentials=admin:admin +controller.credentials=${ODL_USER}:${ODL_PASSWORD} controller.useSsl=false controller.port.http=9999 controller.port.ssl=19999 diff --git a/plugins/grToolkit/provider/src/test/resources/six/gr-toolkit.properties b/plugins/grToolkit/provider/src/test/resources/six/gr-toolkit.properties index 54c9af742..f078634d3 100755 --- a/plugins/grToolkit/provider/src/test/resources/six/gr-toolkit.properties +++ b/plugins/grToolkit/provider/src/test/resources/six/gr-toolkit.properties @@ -23,7 +23,7 @@ adm.fqdn=localhost adm.healthcheck=/adm/healthcheck adm.port.http=9999 adm.port.ssl=19999 -controller.credentials=admin:admin +controller.credentials=${ODL_USER}:${ODK_PASSWORD} controller.useSsl=false controller.port.http=9999 controller.port.ssl=19999 diff --git a/plugins/grToolkit/provider/src/test/resources/three/gr-toolkit.properties b/plugins/grToolkit/provider/src/test/resources/three/gr-toolkit.properties index cc7820e90..040f082df 100755 --- a/plugins/grToolkit/provider/src/test/resources/three/gr-toolkit.properties +++ b/plugins/grToolkit/provider/src/test/resources/three/gr-toolkit.properties @@ -23,7 +23,7 @@ adm.fqdn=localhost adm.healthcheck=/adm/healthcheck adm.port.http=9999 adm.port.ssl=19999 -controller.credentials=admin:admin +controller.credentials=${ODL_USER}:${ODL_PASSWORD} controller.useSsl=false controller.port.http=9999 controller.port.ssl=19999 |