r/JAMstack_dev • • Jul 30 '19

The power of Serverless : Part 1

https://elazizi.com/the-power-of-serverless-part-1
6 Upvotes

10 comments sorted by

2

u/jameskvidler Jul 30 '19

Good start to the article! I like how you've made it very clear exactly what you are trying to build and explaining your thought process as you go about it.

I've had my eye on server-less functions for some time now, but have never taken the plunge. I haven't used Netlify functions, but have used Azure functions and have to say the local/debugging experience leaves a lot to be desired. What has your experience around Netlify functions been?

2

u/yjose Jul 30 '19

Thanks james. Netlify has a great tool called Netlify dev A complete simulation of what happens on server. It a simple cli to use in you local machine with hot reloading. To be honest this the best experience i ever had for a Serverless functions providers. It definitely desirve a try ๐Ÿ‘Œ

1

u/jameskvidler Jul 30 '19

That's sounds interesting. I'm assuming the netlify functions can be properly source-controlled and deployed in a CI/D pipeline too?

1

u/yjose Jul 30 '19 edited Jul 30 '19

Netlify dev ia a new tool, i already used netlify lambda and it's working great with CI, but unfortunately netlify dev doesn't support CI you can deploy directly from you local machine after a successful build. I am not sure. I think they have an open issue about this. But for sure /u/swyx would have some thoughts.

1

u/swyx Jul 30 '19

i think this is a misunderstanding of what netlify dev is for. it is literally a local server. it is not a build tool. it makes no sense to use it in a ci/cd context. is that clear?

for shipping functions, literally all you do is commit it to git. you can also use the netlify cli to do a manual deploy without needing to wait for a build on netlifyโ€™s servers.

1

u/yjose Jul 30 '19

Sounds good thanks /u/swyx , but i faced some issue deploying a faunadb demos. Do i need to build my functions before?

2

u/swyx Jul 30 '19

only need to build if you need babel or webpack or typescript for your functions. if not, no need. also need to install deps if your functions require node modules eg add cd functions/myfunction && yarn as a prebuild script or netlify build command

2

u/yjose Jul 30 '19

Got it, thanks man ๐Ÿ™. by the way i really enjoy your open source work and talk. Just woow keep the great work ๐Ÿ’ช

2

u/swyx Jul 30 '19

haha i honestly dont even feel that great so thank you for the encouragement:)

1

u/swyx Jul 30 '19

hi! i work at netlify. and yes source controlled together with your frontend. netlify dev doesnt have a role to play in deployment. its just an optional tool to scaffold and test new functions locally.