You can book the train ride in Skagway on your own directly through their website. Awesome ride with some wonderful scenery. We did the ride from Skagway to Bennett and on to Carcross, but you can do a roundtrip up to the Canadian border, or you can do a one-way by train and return by van. Check it out; Alaska's most popular Shore Excursion: White Pass & Yukon Route Railroad
For shore excursions, I'm not a big fan of those offered by the cruise line - too crowded, too regimented, and usually not enough time. I much prefer independent companies like Shore Trips.