If you are creating a new application, you can use -O to skip ActiveRecord:
rails new my_app -O
For existing applications:
-
Remove database adapter gems from your Gemfile (mysql2, sqlite3, etc.)
-
Change your config/application.rb
# Rails production setup via SQLite3 made durable by https://litestream.io/ | |
# Copy this to Dockerfile on a fresh rails app. Deploy to fly.io or any other container engine. | |
# | |
# try locally: docker build . -t rails && docker run -p3000:3000 -it rails | |
# | |
# in production you might want to map /data to somewhere on the host, | |
# but you don't have to! | |
# | |
FROM ruby:3.0.2 |
If you are creating a new application, you can use -O to skip ActiveRecord:
rails new my_app -O
For existing applications:
Remove database adapter gems from your Gemfile (mysql2, sqlite3, etc.)
Change your config/application.rb