Who are the people who joined the Israelites?

Ezra 6:21 (ESV)

21 It was eaten by the people of Israel who had returned from exile, and also by every one who had joined them and separated himself from the uncleanness of the peoples of the land to worship the LORD, the God of Israel.

It is unclear if this verse refers to pagans (Gentiles) who converted to Judaism and thus joined in the Passover celebration, or, if it refers to individuals who remained behind Judah or northern Israel when the rest of the people were taken off into exile. These people now separated themselves from their Gentile neighbours to join the Jews. The key idea is that everyone is welcome as long as they separate themselves from pagan worship and devote themselves wholeheartedly to the worship of the Lord.1