A gene coding for human insulin is taken from a human cell and inserted into a bacterium 'vector'. Specifically a plasmid (small ring of DNA), as this will produce the insulin without interfering with normal cell function. A promoter gene is also inserted to promote the production of insulin.
The genetically engineered bacteria are then placed in a fermenter with a nutrient broth. They quickly multiply and produce the insulin, they can't use it so secrete it while we extract it.