Today neither employers not bootcamps would be able to take on risk/exert control over the apprentice's career to the extent optimal from a strictly economic point of view. You can look at the service-for-education deals offered by the military (for both low-skilled and highly skilled people) to get an example - no other organizations would be allowed to restrict a trainee's liberty to the same extent.
While I don't agree with the moral spin that is sometimes put on this of 'greedy juniors' getting trained up and then abandoning their benefactors for higher salaries, this is a real collective action problem, not just shortsightedness in behalf of employers.