A Sydney council has sparked controversy with its new dress code for beachgoers using its popular free bus service.