system k8s-certificate-list commands fails when Opaque type secret data is None

Bug #2065926 reported by ayyappa
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
Fix Released
Medium
ayyappa

Bug Description

Brief Description
-----------------
When any of the k8s Opaque type secret data is None, the "system k8s-certificate-list" command fails

Severity
--------
Major.

Steps to Reproduce
------------------
1)Have opaque type secret with no data on the system
2)Run "system k8s-certificate-list"

Expected Behavior
------------------
"system k8s-certificate-list" should work even if one or few of the opaque type secrets data is None

Actual Behavior
----------------
When any of the k8s Opaque type secret data is None, the "system k8s-certificate-list" command fails

Reproducibility
---------------
100% reproducible.

System Configuration
--------------------
Any.

Branch/Pull Time/Commit
-----------------------
NA.

Last Pass
---------
NA.

Timestamp/Logs
--------------
NA.

Test Activity
-------------
NA.

Workaround
----------
NA

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to config (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/starlingx/config/+/919885

Changed in starlingx:
status: New → In Progress
Ghada Khalil (gkhalil)
Changed in starlingx:
importance: Undecided → Medium
tags: added: stx.10.0 stx.config stx.security
Changed in starlingx:
assignee: nobody → ayyappa (mantri425)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to config (master)

Reviewed: https://review.opendev.org/c/starlingx/config/+/919885
Committed: https://opendev.org/starlingx/config/commit/0e941dc7c21bab8dc01d9d94eae0eb3c38d6f16d
Submitter: "Zuul (22348)"
Branch: master

commit 0e941dc7c21bab8dc01d9d94eae0eb3c38d6f16d
Author: amantri <email address hidden>
Date: Thu May 16 12:25:34 2024 -0400

    Support secrets of data field with None

    Some of the k8s Opaque type secrets data has None values, this
    is failing the "system k8s-certificate-list" command.This fix
    addresses this issue by checking the "data" field in the
    secret

    Test Cases:
    Pass: Have a secret with no data, run "system k8s-certificate-
          list" comamnd and verify it is listing the certificates

    Closes-bug: 2065926

    Change-Id: I85ea4341d71016c6064b22860f761b3f77f1619c
    Signed-off-by: amantri <email address hidden>

Changed in starlingx:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.