The Cabinet isn’t in the Constitution, except to note that the President can ask the opinions of the heads of Executive departments. Those departments are *completely* a creation of Congress, who can restrict them as they see fit.
Since I learned, today, that the Constitution doesn’t mention the cabinet, I think Congress should pass a law that will say that, as soon as a military member is discharged from active duty, he or she may be in a cabinet. Someone who was discharged a week ago knows more about the current military needs, compared to someone who was discharged seven years ago, since some military rules and problems might have changed, within the last seven years.