Associating Controllers with pre-existing database/s

As a Rails newbie, apologies if I'm about to ask a dumb question.
All the Rails tutorials I've followed start by creating a database from
scratch, is there any way of using a pre-existing database to establish
the Rails MVC framework? I know I can do all the work by hand, but it
seems to me there should be a way of extracting the schema information
from the database/s, and using this to generate basic scaffolding.
The database in question is in SQlite3 format.