After you have gotten eight Gym Badges, you can go through the Pokémon League building west of Viridian City, which leads to Route 23.
Show Your Badges
Go east from the Route 23 entrance to find a set of 3 Golden Razz Berries.
Make your way north and the guards will let you pass as they check your Gym Badges.
After you pass through the Thunder Badge gate, go east to find a set of 3 Golden Nanab Berries.
After you pass through the Rainbow Badge gate, you will surf in the water. Surf west in the water to find a set of 3 Golden Pinap Berries.
After you pass through the Soul Badge gate, there is an island to the north where you will find a set of 5 Golden Razz Berries.
After you pass through the Marsh Badge gate and go north, you will be back on land. Go northeast into the patch of grass to find a set of 5 Golden Nanab Berries between the two Poké Ball statues.
After you go north through the Volcano Badge Gate, check in the grass to the north to find a set of 5 Golden Pinap Berries.
Go west from that grass, then go north to pass through the gate into Victory Road.