I'd but the elbow into the seam so that the box could come apart if needed.
Also to allow for a bit of flex room. Every time I have welded things solid on a stepside bed it seems that I end up with cracks near some of the welds due to normal flexing of the bed when the truck negotiates the roads, driveways and entrance of parking lots.
You will have to find the correct radius elbow with the correct diameter tube. I'd check with suppliers of tubing for headers for that. Speedway has a pretty good selection of bends to choose from including this combo one
http://www.speedwaymotors.com/Combo-...Inch,4563.html.