This is a blank project to get started with Rails, Docker and Postgres. Once you get the Rails app going please change the Dockerfile and docker-compose.yml to suit your needs.
docker compose build
docker compose up
Then go to docker desktop Find the container and open a shell and type
rails new . --force --database=postgresql