I just assume that the Whitebeard pirates did something to open the gate, otherwise why would it have opened for Luffy.