The absolute commandment is to be fruitful, which Joseph and Mary were in the most glorious fashion in bringing us the Savior. In many instances the Church allows for complete abstinence in marriage, when the fruit of the marriage is either already present or impossible. That is called Josephine marriage and is perfectly valid. An example would be a couple wishing to join monastic orders.
The commandment of submission to the husband remains valid, of course, but Mary would have violated it only if Joseph had asked her physical affection, of which we have no record.
In any event, the uniquely exceptional nature of the Holy Family renders all attempts to find a legalistic fault in them stupid and vaguely blasphemous.
Joseph had nothing to do with that union.
His fruitful union with Mary Came later.
Matthew 1:24
Then Joseph being raised from sleep did as the angel of the Lord had bidden him, and took unto him his wife:
25 And knew her not till she had brought forth her firstborn son: and he called his name JESUS.