“Three other federal courts have ruled in favor of the CDC's eviction moratorium, including a U.S. Court of Appeals for the D.C. Circuit ruling in June.
That same month, the U.S. Supreme Court refused to take up an emergency petition to hear a challenge to the moratorium, although a majority of five justices did indicate that they considered the policy illegal.”
It’s less clear cut than your suggesting. The Supreme Court left the memorandum in place 5-4 while saying they would reject continuing it without congressional involvement. So, it looks like the CDC could do this on the next pandemic, just not for this one.