- Docker
git clone https://github.com/vinchi777/demoapi
cd && docker-compose build
docker-compose up
docker-compose run rails_api rails db:create
docker-compose run rails_api rails db:migrate
cd data/db/
sudo chown -R $USER:$USER .
docker-compose run rails_api rails g model User
docker-compose run rails_api rails db:migrate
docker-compose run rails_api rails console
GET localhost:3000/notes
POST localhost:3000/notes
{
data: {
attributes: {
subject: "Test",
body: "Test,
}
}
}