Skip to content

Simple microservice that displays data of select characters, monsters, and games from the Final Fantasy series

Notifications You must be signed in to change notification settings

LAMaglan/FinalFantasyFast

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

76 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Note: a fair amount of help from ChatGPT throughout

The microservice can be run with or without docker-compose

Screenshot from 2024-08-27 15-10-32

Screenshot from 2024-08-27 15-11-00

Run with docker-compose

docker-compose up

Note: if you for whatever reason make changes to the dockerfiles or docker-compose.yml files, the rebuild with

docker-compose up --build

Note: nginx is somewhat superflous, unless this is deployed on a remote server, with many users, and/or larger data

Run without docker-compose

Note: not so trivial to do with postgres. Switch back to sqlite. Last working version with sqlite:
https://github.com/LAMaglan/FinalFantasyFast/tree/8c592d633d37a16d3facbe26c92949ad50d0153a

The backend (FastAPI) runs with poetry:

cd backend
poetry shell
python intialize_db.py
uvicorn main:app --reload

Frontend runs on React.js , using axios to make HTTP requests to the FastAPI backend. To run the frontend (while the backend is running), do:

cd react-frontend
npm start

Details on the running services

The backend retrieves data from external Final fantasy api https://www.moogleapi.com/

With default settings, you can test out the API through swagger docs: http://127.0.0.1:8000/docs/ or http://0.0.0.0:8000/docs/ if using the docker-compose approach.

The characters and monsters routers fetches data from the above link, and stores them in a postgres database. Note: the use of (postgres) database is somewhat superflous, there are no POST endpoints in the backend API.

The frontend is accessible through http://localhost:3000

About

Simple microservice that displays data of select characters, monsters, and games from the Final Fantasy series

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published