Yes, it depends very much where you are. In Europe it is unwise to go ashore without your passport. Why not ask at the desk about your particular cruise? They're there to help.
Me, I carry the passport, period. That's why I have it. It's in a pouch strung around my neck under my shirt. It's like we've said over and over here: if you have your passport, you're in business. It is the trump card. Trying to outguess and outsmart the local authorities is a low percentage game and not worth playing, especially at a time when the rules are--to say the least--in flux.
The cruise we just returned from in Europe, on the Celebrity Constellation, all we required was the shipboard card (the picture was digitally embedded on the card). Previously, even with that system, we also need a picture ID.
I would carry my shipboard sail & spend card AND a photo id such as my DL and as a matter of habit my credit card which also happens to have my photo on it. In most cases all you need is the S&S card as the new procedures involve your photo coming up when you place your card in the security reader. I never take my Passport ashore as I do not wish to lose it. While in Europe onboard a cruise ship, and in the Caribbean if you are not a US Citizen, they will collect your passport when you board and keep it until the end of the cruise so you will not have it to take ashore. That saves the time and trouble of having everyone cleared before you can disembark.
Your cruise line will tell you exactly what is required. I carry a photocopy of my Passport (safely stored on board) together with whatever the ship gives me when I board and show when I get off - if they clocked me off, seems reasonable to assume that I will be clocked back on again - :-)
We just came back from 15 days onboard the Carnival Legend. Boarded in Europe and sailed it to NYC. The passports were taken from us when we boarded and we did not get them back until the day before we landed. Same thing happened on the Princess ship we were on in the Orient last year. So, no passports in port -- simply not possible.