Remove unused cps auth params from DMI 82/141182/2
authormpriyank <priyank.maheshwari@est.tech>
Tue, 10 Jun 2025 11:27:12 +0000 (12:27 +0100)
committermpriyank <priyank.maheshwari@est.tech>
Tue, 10 Jun 2025 14:01:04 +0000 (15:01 +0100)
- we have removed spring security from CPS repo hence cleaning up the
  auth related parameters
- updating the documentation related to the same

Issue-ID: CPS-2841
Change-Id: Ia1deab32ad6b39346a3c9793a1ea5a4c17e3a7f7
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
csit/plans/dmi/test.properties
dmi-service/src/main/java/org/onap/cps/ncmp/dmi/config/DmiConfiguration.java
dmi-service/src/main/resources/application.yml
dmi-service/src/test/groovy/org/onap/cps/ncmp/dmi/config/DmiConfigurationSpec.groovy
dmi-service/src/test/resources/application.yml
docker-compose/README.md
docker-compose/docker-compose.yml

index 2929eb6..e56576a 100644 (file)
@@ -10,8 +10,6 @@ SDNC_PASSWORD=Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U
 CPS_CORE_HOST=$LOCAL_IP
 CPS_CORE_PORT=8883
 CPS_CORE_MANAGEMENT_PORT=8887
-CPS_CORE_USERNAME=cpsuser
-CPS_CORE_PASSWORD=cpsr0cks!
 
 DMI_HOST=$LOCAL_IP
 DMI_PORT=8783
index dee3c75..daca4ee 100644 (file)
@@ -47,10 +47,6 @@ public class DmiConfiguration {
         private String dmiRegistrationUrl;
         @Value("${cps-core.dataSyncEnabledUrl}")
         private String dataSyncEnabledUrl;
-        @Value("${cps-core.auth.username}")
-        private String authUsername;
-        @Value("${cps-core.auth.password}")
-        private String authPassword;
     }
 
     @Getter
index d639932..7ba9b25 100644 (file)
@@ -109,9 +109,6 @@ cps-core:
   baseUrl: http://${CPS_CORE_HOST}:${CPS_CORE_PORT}
   dmiRegistrationUrl : /ncmpInventory/v1/ch
   dataSyncEnabledUrl: /ncmp/v1/ch/{cmHandleId}/data-sync?dataSyncEnabled=true
-  auth:
-    username: ${CPS_CORE_USERNAME}
-    password: ${CPS_CORE_PASSWORD}
 
 sdnc:
   baseUrl: http://${SDNC_HOST}:${SDNC_PORT}
index 9637371..8f3aa0e 100644 (file)
@@ -40,8 +40,6 @@ class DmiConfigurationSpec extends Specification {
         expect: 'CPS properties are set to values in test configuration yaml file'
             cpsProperties.baseUrl == 'some url for cps'
             cpsProperties.dmiRegistrationUrl == 'some registration url'
-            cpsProperties.authUsername == 'some cps core user'
-            cpsProperties.authPassword == 'some cps core password'
             cpsProperties.dataSyncEnabledUrl == 'some data sync url/{some-cm-handle}?dataSyncFlag=true'
     }
 
index 2a2cf96..2a6269a 100644 (file)
@@ -37,9 +37,6 @@ cps-core:
   baseUrl: some url for cps
   dmiRegistrationUrl: some registration url
   dataSyncEnabledUrl: some data sync url/{some-cm-handle}?dataSyncFlag=true
-  auth:
-    username: some cps core user
-    password: some cps core password
 
 dmi:
   service:
index 109cc62..a14aa3d 100644 (file)
@@ -1,6 +1,6 @@
 <!--
   ============LICENSE_START=======================================================
-  Copyright (c) 2021 Nordix Foundation.
+  Copyright (c) 2021-2025 OpenInfra Foundation Europe. All rights reserved.
   ================================================================================
   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
@@ -63,7 +63,6 @@ dmi-plugin can be started either using a Java Archive previously built or direct
 Following command starts the application using JAR file:
 
 ```bash
-CPS_USERNAME=cpsuser CPS_PASSWORD=cpsr0cks! \
   java -jar ncmp-dmi-plugin/target/ncmp-dmi-plugin-x.y.z-SNAPSHOT.jar
 ```
 
@@ -72,8 +71,7 @@ CPS_USERNAME=cpsuser CPS_PASSWORD=cpsr0cks! \
 Here are the steps to run or debug the application from Intellij:
 
 1. Enable the desired maven profile from Maven Tool Window
-2. Run a configuration from `Run -> Edit configurations` with following settings:
-   * `Environment variables`: `CPS_USERNAME=cpsuser CPS_PASSWORD=cpsr0cks!`
+2. Run a configuration from `Run -> Edit configurations`
 
 ## Accessing services
 
index 859ddb5..7411c24 100755 (executable)
@@ -1,5 +1,5 @@
 # ============LICENSE_START=======================================================
-# Copyright (C) 2021-2022 Nordix Foundation
+# Copyright (C) 2021-2025 OpenInfra Foundation Europe. All rights reserved.
 # Modifications Copyright (C) 2021 Bell Canada.
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 services:
   ncmp-dmi-plugin:
     container_name: ncmp-dmi-plugin
-    image: ${DOCKER_REPO:-nexus3.onap.org:10003}/onap/ncmp-dmi-plugin:${DMI_VERSION:-latest}
+    image: ${DOCKER_REPO:-nexus3.onap.org:10003}/onap/ncmp-dmi-plugin:${DMI_VERSION:-1.8.0-SNAPSHOT-latest}
     ports:
       - ${DMI_PORT:-8783}:8080
     environment:
-      CPS_USERNAME: ${CPS_CORE_USERNAME:-cpsuser}
-      CPS_PASSWORD: ${CPS_CORE_PASSWORD:-cpsr0cks!}
       CPS_CORE_HOST: ${CPS_CORE_HOST:-cps}
       CPS_CORE_PORT: ${CPS_CORE_PORT:-8080}
-      CPS_CORE_USERNAME: ${CPS_CORE_USERNAME:-cpsuser}
-      CPS_CORE_PASSWORD: ${CPS_CORE_PASSWORD:-cpsr0cks!}
       SDNC_HOST: ${SDNC_HOST:-sdnc}
       SDNC_PORT: ${SDNC_PORT:-8181}
       SDNC_USERNAME: ${SDNC_USERNAME:-admin}