Did Rama kill a king Shambuka, who is a Sudra, for doing penance? The Answer is YES. Was it a myth? NO. If you believe Ramayana is not a Myth, then this incident is not a myth as well. Because it was written by the same sage Valmiki who wrote Ramayana. Was Rama cruel in doing this ? NO. He did his duty as a king... How? You have to read the article to know that.
Before prejudicing Lord Rama as a racist we need to understand what the varna meant during Treta Yug. Every Varna (Not to misunderstand with the word Varnam, Colour) meant a profession. Brahmana means a person who can be a teacher or priest, Kshtriya will be the ruler or warrior, Vaishya would be the farmer and Shudra will be the merchants, entrepreneurs and service providers. Any human being can get into any profession based on his skill sets. And he will be referred to by his Varna, as we call doctor a doctor and Waiter and Waiter in the modern days. The Varna was not decided by birth rather by the qualification and skills one procured. Understanding lets get into the controversial part which happened during Uttara Ramayanam era. Lord Rama Killed a Sudra king Shambuka while he was performing penance. Sage Valmiki has endorsed saying this incident did happen. When Sage Narada went and complained to Rama about Shambuka performing penance / Tapasya, King Rama was worried. It was considered to be an Adharama of those days. In fact it is Adharma in today's world too if we set aside the perceptual prejudice we have on Rama. Will you accept a pharmacist or a Lab assistant to perform an open heart surgery? Are we okay with a bearer of a restaurant to build a 21 store building? Same thing will happen to this world if a person who is not well-versed in the process of penance does that. In Treta yuga, or even till Dwapara yuga many people were equipped with some cosmic powers. During Kali yuga, in which we live we are not blessed to carry any such powers. When you have access to cosmic powers which can bring in connections with ExtraTerrestrials or Devas or gods you cannot perform tapas / penance with a half baked knowledge. It can lead to a disaster and that would eventually destroy the peace and harmony of the public. We all know what happened when a virus named Corona spouted out of a Chinese lab. Lord Rama being the emperor of Akanda Bharath, he took a decision to kill a man who wasnt an expert in performing penance. The community which is referred to in the modern days is not connected to the Varna which has been quoted in Uttara Ramanayam. If you are still not satisfied then you should read further ... "Rama Rajyam was based on Chaturvarna. Rama was not to be blamed as he followed what Dharma insisted him to follow" was told by Dr. B.R. Ambedkar.
Chaturvarna is all about people belonging to one of the 4 Varnas based on their skill sets, abilities and characters. But over the period in Kaliyuga it got diluted and the varnas were decided by birth. To support what I quote here, there is a sequence in Mahabharata. When Pancha Pandavas took sanyasam along with Draupati, they meet a serpent on their way. The serpent questions Yudishtra "Who is Brahmana and Who is Shudra?" . For which Yudhisthtra explicitly states that "neither Brahmana nor Shudra belong to a particular Varna simply because they are born into it (i.e. They are born into that family)". He further states that it was very difficult to determine one’s Varna in human society owing to the promiscuous intercourses among all the four Varnas, thus resulting in mixed Varna offsprings. (Mahabharata 3.177). So my submission in this article is that Rama did not kill a king of a particular community considering them to be inferior for doing penance. He killed the king as it was a misdeed to perform something which you are not entitled or qualified to do. Which is very much in practice in the modern world. Jai Shri Ram!!