You don't. The G18 was designed so that its components could not
be dropped into a Glock 17 (or any other Glock pistol).
Furthermore, without the appropriate Federal Firearms Licence and
Special Occupational Tax, it's illegal to convert semi-auto
firearms into full auto.