Deploy FastAPI on Vercel | Quick and Easy Tutorial

Поділитися
Вставка
  • Опубліковано 2 гру 2024

КОМЕНТАРІ • 51

  • @phani3519
    @phani3519 6 місяців тому +1

    best fastapi mentor ever

  • @oluwatosin001
    @oluwatosin001 5 місяців тому +1

    i did this but i have an issue where I created a new folder and that's where most of my endpoints logic are but I can see it in the docs of the API

  • @rangabharath4253
    @rangabharath4253 6 місяців тому +2

    Awesome as always 🙂

  • @gauravwankhede9263
    @gauravwankhede9263 Місяць тому +1

    Thank you sir for this Awesome tutorial. ❤
    I am wondering how this deployed backend server can be used for the NextJs Frontend app?
    If you can make a tutorial it will help is alot. 😊

    • @codingwithroby
      @codingwithroby  Місяць тому +1

      I have a NextJS video that may help you with this 🙂

    • @gauravwankhede9263
      @gauravwankhede9263 Місяць тому +1

      @@codingwithroby Thank You for your reply. I am thinking to deploy FastAPI As a backend and for frontend I am using NextJS.

  • @123TRATRATRA
    @123TRATRATRA 6 місяців тому

    Eric ma man, it was the right time to make a project given you just posted, keep it up!

  • @wiktor6436
    @wiktor6436 Місяць тому

    thanks, it's very valuable tutorial

  • @vitvitvitvitvitvitvitvit
    @vitvitvitvitvitvitvitvit 3 місяці тому

    thanks, man! the node 18.x version set python 3.9 version. There is a way to use python 3.12, which is the default, while using node 18.x?

  • @finnbenson1826
    @finnbenson1826 Місяць тому

    Really great stuff thank you! i think the hobby tier allows you to host up to 200 sites i just read somewhere. Can't believe it is free which is fantastic although there is no reason why web hosting should be super expensive in this day and age for basic performance anyway. I will definitely pay for a Vercel plan if my apps start to scale

  • @tattat4042
    @tattat4042 6 місяців тому +1

    Thanks Eric, great job

    • @codingwithroby
      @codingwithroby  6 місяців тому

      You are so welcome!

    • @tattat4042
      @tattat4042 6 місяців тому

      @@codingwithroby Appreciate your fix at the end to switch from 20.x to 18.x which I have spent sometime trying to fix but couldn't until I found your video.
      Could you please show us how to call fastapi from react in Vercel? I tried but facing a CORS issue

  • @boundless-sher
    @boundless-sher 6 місяців тому +1

    where do you deploy a fastapi backend with database though?

    • @codingwithroby
      @codingwithroby  6 місяців тому

      Me specifically? If I want to deploy with a database like PostgreSQL or mySQL I would use AWS or Heroku.

    • @boundless-sher
      @boundless-sher 6 місяців тому +1

      @@codingwithroby can u make a tutorial on it or let me know if you already have one

    • @codingwithroby
      @codingwithroby  6 місяців тому +4

      If you are wanting to use AWS - I am currently building a course right now. It will be a paid course but will cover creating an AWS account, using the services, getting a deployed FastAP, React, and database application with your own custom domain and SSL, all connected by CICD on Github. Pretty cool course overall.

  • @Andromeda26_
    @Andromeda26_ 6 місяців тому

    Awesome, Can you please create a simple react and use it as the front along side FastApi and deploy both on vercel?

    • @codingwithroby
      @codingwithroby  6 місяців тому +1

      You can deploy the FE (very similar way) and have it point to your deployed FastAPI application for the API calls.

  • @arpy8
    @arpy8 6 місяців тому +2

    Ahhh you're a saviour, i was so frustrated because of this severless function getting crashed again and again, THANK YOU SO MUCH!!! h❤❤❤❤❤❤

  • @lordareello8221
    @lordareello8221 3 місяці тому

    Hi please can I use this with jinja templates... awesome tutorial

  • @مبشر
    @مبشر 6 місяців тому

    Great Mentor!! But unfortunately my error didn't solve 😞. Whenever I add firebase admin or supabase, I get FUNCTION_INVOCATION_FAILED error. Also tried changing node version, same thing happens always. Is there any solution for it?

    • @codingwithroby
      @codingwithroby  5 місяців тому

      Hmm does it work without firebase/supabase stuff? My guess would be environmental variables are off

  • @vrajentertainments4288
    @vrajentertainments4288 3 місяці тому

    how about the ci/cd pipelines

    • @codingwithroby
      @codingwithroby  3 місяці тому

      I can look into making a video for that.

  • @AliAsif-kq8cd
    @AliAsif-kq8cd 6 місяців тому

    i am deploying sql model with fastapis and still got this sever error after fixing everything

    • @codingwithroby
      @codingwithroby  6 місяців тому

      Start over - and do exactly as I do it - step by step. Change Node to 18.

  • @emmanuelparvez5234
    @emmanuelparvez5234 3 місяці тому

    Is there a way to deploy react with this API?

    • @codingwithroby
      @codingwithroby  3 місяці тому

      Yeah - I got you: www.udemy.com/course/deploy-fastapi-fullstack-amazon-cloud-aws/?referralCode=706861EF28A616B36FEC

  • @مبشر
    @مبشر 3 місяці тому

    Does vercel support websockets?

  • @JbrDeveloper
    @JbrDeveloper 6 місяців тому

    what we can do if our api is connected with mysql?

    • @codingwithroby
      @codingwithroby  6 місяців тому +1

      You can deploy your database separately on something like AWS RDS and connect it from there.

    • @JbrDeveloper
      @JbrDeveloper 6 місяців тому

      @@codingwithroby Ohh great idea thank you so much teacher

  • @Avvenio
    @Avvenio 5 місяців тому +2

    Wow, I haven't been so impressed by a UA-camr in terms of setting, lighting, voice and look for a long time! Really great! Subscribed!
    I was wondering, could we have both nodejs and python routes in our api folder in the same project? Or would the runtime be set once per project in vercel?

    • @codingwithroby
      @codingwithroby  5 місяців тому +1

      Aww thank you! I spent time & money figuring lighting and camera out lol. Unfortunately on vercel the runtime needs to be configured for the product. You could probably do it, but better if it is two separate applications.

  • @cherryjayhawk4845
    @cherryjayhawk4845 6 місяців тому

    I almost dead by this FUNCTION_INVOCATION_FAILED error. Tysm dude!

  • @juangonzalezcabello1737
    @juangonzalezcabello1737 27 днів тому

    wtf, why do you force me to subscribe to your nl for a 6 min video? It really makes me want to not subscribe and report you as spam... Give me the option and i will do it happy, but force me? pass...

    • @codingwithroby
      @codingwithroby  27 днів тому

      No forcing happening over here, feel free to type out the code - it's all there in the video.

  • @Sam-u6c2v
    @Sam-u6c2v 6 місяців тому

    im still receciing this crazy bug what the heck I cannot for the life of me figure this out
    This Serverless Function has crashed.
    Your connection is working correctly.
    Vercel is working correctly.
    500: INTERNAL_SERVER_ERROR
    Code: FUNCTION_INVOCATION_FAILED
    ID: iad1::fxfwz-1716771331917-75192ab98bae

    • @codingwithroby
      @codingwithroby  6 місяців тому

      And you changed the node version? Make sure your project is structured correctly

    • @saltukkezer5100
      @saltukkezer5100 6 місяців тому

      @@codingwithroby Does the main.py have to be inside the api folder? What happens if it is not, and how does it matter? I have an existing project and try to deploy it on vercel but it does not work.

    • @codingwithroby
      @codingwithroby  5 місяців тому

      @@saltukkezer5100 It does if you want to follow this step by step. You will have to change the vercel path to whatever your path is.