You don’t need to drill a hole in the pipe. Just purchase a PVC pipe coupler that is about the size of a seat post, 1/4-20 nut, two 1/4" fender washers, a 1/4-20 bolt long enough to go through the pipe coupler, fender washers, and rack reflector tab.
Assemble the pipe coupler with a fender washer on each end and insert the 14-20 bolt through the washers, coupler, and rack tab. Tighten the 1/4-20 nut so everything is firmly held in place. Install the taillight on the pipe coupler just as you would clamp it on the seat post.