I am going to be stopping in Estonia during a cruise. I have knee trouble but don't want to ride a bus to see Estonia. If I stay in old town how is the terrain? Will there be a lot of uphill walking? Or is it fairly flat? How far is it from the port to old town?
Tallinn is hilly, but there are areas you can walk and avoid the hills. There is a section of the old town (called the Upper Town) that is on top of a hill, and you might not make it there if you're concerned about hills and steps.
Rick Steves has a walking tour of Tallinn on the Smithsonian Magazine website. This should give you a rough idea of what to expect.
I arrived and departed by ferry, not cruise ship, so I don't know the distance from the cruise terminal to the old town. From the ferry it was about a 15 minute walk if I remember correctly, and I don't recall any hills between the ferry terminal and the old town.
As Lane says, yes, there are hilly areas but still plenty to see in the lower part of Old Town, and on into the more modern area. There are cobblestones everywhere and that can get me tired more quickly than flat sidewalks. Tallinn is great fun to explore, has a pleasantly busy vibe, not at all overwhelming like many other capital cities. I stayed in old town and took a taxi to the ferry when I made a day trip to Helsinki, partly because it was 6 am when I left and mainly because it's a 15-25 minute walk. Taxis are plentiful, shouldn't cost more than 10-15 euro.
If you're curious about taking a guided tour, either walking, half or full day to other areas, I highly recommend EstAdventures, had 2 wonderful day trips with them--excellent and friendly guide (the owner himself!) and limited to just 4 people.
Don't know if you've left for your cruise yet but I was on a Baltic cruise that stopped in Tallinn. It's not a long walk from where they let you off into the old city. Tallinn is a lovely town. You don't need a guide - I used Rick Steves' walking tour. It's a very friendly place - they survived the Nazis and the Soviets and are very proud of their country. Read about the "singing revolution" on YouTube. You don't need to bother walking up to the Russian part of the city. It's just a church. Lots of nice shops and restaurants below. The old churches are very interesting. They're the least religious country of Europe and are still kind of pagan!