Closed rbarisic-lme closed 1 month ago
No, sorry the docker-compose.yml in the root directory was a bit confusing. This repo borrowed the backend code from fastapi official full stack template. But the original one is not using nextjs. Also, the original repo was written based on deployment to a vm/kubernetes. The new concept in this repo is to use all the free serverless stuff! so you would have nextjs deployed to vercel, fastapi deployed to cloud run and postgres hosted on supabase. No cost for running a fully scalable solution. Refer the doc below for local development. You would only use Supabase cli to spin up a local supabase instance via docker. No need for docker compose in this case. https://github.com/Sheldenburg/ai-engineer-template/blob/main/development.md
I see that celery workers will be added in the future. Where would that be hosted if the intention is to be purely serverless? Is there a timeline for celery support?
@by14 , good question. There are some serverless options for celery https://aws.amazon.com/blogs/hpc/run-celery-workers-for-compute-intensive-tasks-with-aws-batch/ or use cloud tasks on gcp https://cloud.google.com/tasks/docs https://www.reddit.com/r/googlecloud/comments/sces9v/new_to_gcpcloud_run_and_having_problems_with/
@Sheldenburg thanks for the info, we figured this one out after some hours. The setup process was a bit confusing as I didn't know it was intended for serverless deployment.
I have forked the repo to reuse Docker for backend and supabase deployment, where supabase is just ran with the npm supabase start command and the backend is added to the supabase Docker network.
Sadly, I can't make a pull request to your repo, since I made too many changes for my use case. But maybe a heads up or deletion of useless files can help people in the future.
Thanks for putting together this stack, it's much appreciated 👍
@by14 please open another issue if you have a question that is not related to an issue's topic, it keeps conversations clean and also I don't get email notifications for unrelated topics.
The original template seems to feature a backend/api folder. In there we have Dockerfile, and the docker-compose sits at the root of the project. Here, we have 2 docker-compose.yml that don't do the same thing. I would expect the root docker-compose to create all the sub services in frontend, backend and supabase