Rig = truck?

Why is a big truck (i.e. 18 wheeler) referred to as a rig?

A more generic definition of rig might be a piece of equipment. Thus rig can describe a truck, a drilling rig or an intravenous drug user’s syringe.

Rig frequently implies the use of lines to assemble something. Sailing ships are identified by their rigs. The word also shows up in a similar fashion to identify a team of horses and carriage. I can see two possible ways to get from team and carriage to tractor-trailer:
for one, a tractor-trailer, unlike a flatbed truck, a pickup truck, or a van, needs to have the trailer harnessed to the tractor. (No, the actual connection is not a harness but the “fifth wheel,” but the brake and signal light connections and the brake lines need to be connected to make the vehicle safe);
for another, once teamsters were in the habit of referring to their teams and wagons as rigs, it would have been natural to call the successor equipment by the same word.