Browse Source

Change Mtce token endpoint lookup to be 'platform'.

The maintenance token request's response parser is looking
for nova compute endpoint as a day one implementation when
mtce actually managed nova. That is long since changed but
this endpoint lookup remained.

In the new containterized environment the nova compute
endpoint is not always present and when its not mtce
fails to get its token.

Since mtce needs the token for communication with sysinv
this update changes the endpoint lookup type to 'platform'
to match that of sysinv.

Change-Id: I389b64d345e47f7d7bc062671da7c7cc51ac398f
Story: 2004695
Task: 29213
Signed-off-by: Eric MacDonald <eric.macdonald@windriver.com>
Eric MacDonald 2 months ago
parent
commit
ff8ef3ea8a

+ 1
- 1
mtce-common/centos/build_srpm.data View File

@@ -1,3 +1,3 @@
1 1
 SRC_DIR="src"
2
-TIS_PATCH_VER=141
2
+TIS_PATCH_VER=142
3 3
 BUILD_IS_SLOW=5

+ 1
- 1
mtce-common/src/common/jsonUtil.cpp View File

@@ -847,7 +847,7 @@ int jsonApi_auth_load    ( string & hostname,
847 847
             {
848 848
                 tuple_obj = _json_object_array_get_idx (svccat_obj, i);
849 849
                 entity = _json_get_key_value_string ( tuple_obj, MTC_JSON_AUTH_TYPE );
850
-                if ( entity == MTC_JSON_AUTH_COMP )
850
+                if ( entity == MTC_JSON_AUTH_PLATFORM)
851 851
                 {
852 852
                     found_type = true ;
853 853
                     break ;

+ 1
- 1
mtce-common/src/common/jsonUtil.h View File

@@ -40,7 +40,7 @@ typedef struct
40 40
 #define MTC_JSON_AUTH_ISSUE     "issued_at"
41 41
 #define MTC_JSON_AUTH_EXPIRE    "expires_at"
42 42
 #define MTC_JSON_AUTH_ID        "X-Subject-Token"
43
-#define MTC_JSON_AUTH_COMP      "compute"
43
+#define MTC_JSON_AUTH_PLATFORM  "platform"
44 44
 #define MTC_JSON_AUTH_INTERFACE "interface" /** looking for admin */
45 45
 #define MTC_JSON_AUTH_ADMIN     "admin"
46 46
 

Loading…
Cancel
Save