Does that mean that only 5 other nodes know about the transaction until it is confirmed in a block, or does the amount of nodes keep increasing until a mining node sees it?
You send a transactions to the nodes you are connected to. These will verify the transaction to make sure its according to (their specific) rules. If its not, they drop it. If the transaction is sound to them, they will relay it to all other nodes they are connected to. It usually takes a few seconds until a transaction is known to all (mining) nodes.