Accu Weather is a Rails API Only for working with AccuWeather API.
It uses Postgres, Redis as a cache, and Swagger. This application is available to run in a Docker environment (see the instructions below).
ACCUWEATHER_API_KEY=aPmXW3zSMgsz4K84mkY8fVRokC5xkAZY # Or <your_api_key>
DB_HOST=localhost
DB_USERNAME=dummy
DB_PASSWORD=password
- Check db username and password in your local machine
rails db:setup
rails s
http://localhost:3000/api-docs
docker compose build
OR generate the Rails skeleton app using
docker compose run --no-deps web rails new . --force --database=postgresql
docker compose up
docker compose run web rails db:setup
servers:
- url: http://0.0.0.0:3000
curl http://0.0.0.0:3000/api/v1/health
http://0.0.0.0:3000/api-docs