Deploy FastApi to Aws Lambda for Serverless Hosting!
Вставка
- Опубліковано 19 сер 2024
- I show how to deploy a FastApi app to an Aws Lambda with a Function Url to allow for serverless hosting of your Api with Https traffic out of the box. Repo: github.com/vas...
Vincent you are the freaking man! I tried to do this using 3 other tutorials and I was at it for hours and kept getting stuck at various places. I used your method and was up and going in less than 15 minutes! You need to set up a tip jar or something on UA-cam!
Keep going on mate ! Very excited to see your expansion and the knowledge that you will bring along with it !!
When you send a request through the lambda, does the app gets initialized again or it stays initialized? so for example if i had object that has longer loading time will it affect the performance?
what are the benefits of using AWS Lambda instead of using docker directly on the EC2 machine?
i tryed but i got [ERROR] Runtime.ImportModuleError: Unable to import module 'main': No module named 'pydantic_core._pydantic_core' Traceback (most recent call last):
aws lambda deployement of fastapi gives the following error :
[ERROR] Runtime.ImportModuleError: Unable to import module 'users_crud': No module named 'pydantic_core._pydantic_core'
Traceback (most recent call last):
Though the pydantic lib is already installed. Any ideas any clues why ? I am using 3.10 which is now supported by AWS
Hi @sarc007 Did you end up solving this issue? I am running into the same thing.
does it working if i use postgresql as my db?
Great video. But zip command dosnt work in windows. Please highlight that and if there is any work around please post it too.
thanks
i studied biology in college and have no comprehension of the language you are talking in this video.
where'd you pick up all of this technical jargon? i'm assuming it's still much more enjoyable than medical school jargon?
You need some general knowledge of web services i.e. how the internet works. And he's also using AWS for deployment which is a mountain of jargon in itself. Just takes time and experience.
@@barnabuswizardspook that's fascinating how much i just don't know.
at times, the medical jargon feels equally insurmountable.
sometimes, i think that i'd be more productive (in society, and for myself) if i instead learn and apply the tech/web services jargon...
In fact, the idea of using fastapi in a lambda is a strange idea in and of itself! The lambda is made for others like stateless event processing. Definitely not for runnig api servers inside.
Nope! It's perfectly fine to use API on Lambda. For me it's the only purpose of using Lambda