Deploy your Nodejs + Auth0 REST API to Cyclic.sh under 4ย minutes

_iametornam

Etornam๐Ÿคด๐Ÿฝ๐Ÿ‡ฌ๐Ÿ‡ญ

Posted on December 16, 2021

Deploy your Nodejs + Auth0 REST API to Cyclic.sh under 4ย minutes

Deploying APIs can sometimes be a pain in the butt when your service provider overcomplicates the deployment and setup process. This short article will demo how to deploy your Restful Nodejs application to Cyclic.sh in less than 4 minutes.

Yes!, you heard right, less than 4 minutes๐Ÿ”ฅ๐Ÿ˜ฑ๐Ÿ˜ฑ.

from cyclic.sh homepage

Cyclic is a provider that helps you Launch your API in seconds. Push your code to Github and let the CI/CD (continuous integration/continuous delivery) integration trigger and deploy your service onto a global infrastructure in seconds. No cryptic CloudFormation errors. No mysterious API Gateway errors. No YAML parse errors. No hunting for CloudWatch log groups. No wasted time.

Important!
I already have my Nodejs Auth0 backend done.

To follow along with this project, clone the repo from here.

Deployment Demo
To deploy your codebase, follow the following steps:
The first thing you must do is create a repository on github.com for your project and push your code.

Github repo create page

Next, signup to Cyclic.sh. The signup process is seamless, and all you need is to signup using your Github account.

cyclic.sh signup page

After successful signup, you will see a dashboard; where all the magic happens. You can locate the docs at the top right corner, just right before the profile.

locate docs at the top right corner

Now you need to deploy your code. Click the "deploy" button (green button) and select the "Link your own" tab.

deploy button

link your code from Github

Search for the repo you want to deploy, in your case "nodejs-auth0," and select it and connect it to your Github account.

Image description

At the prompt, you need to confirm your Github access, and after confirming, all you have to do is to approve and install, and that's it ๐ŸŽ‰

Image description

Once you approve and install, the deployment process will start. 2โ€“3mins should do it ๐ŸŽŠ๐ŸŽ‰๐ŸŽŠ๐ŸŽ‰๐ŸŽŠ๐ŸŽ‰

Image description

The final step is to set your environment variables on the dashboard. The dashboard for your project looks like this.

Image description

This is a ".env" file; you can also include those configurations on the dashboard by clicking on "Variables." After this configuration, everything should be up and running ๐Ÿ”ฅ

Image description

Deploying new changes
After all the setups and configurations, to deploy new changes, push your code to Github, and Github actions will do the rest ๐Ÿ˜€๐Ÿ˜‰

Conclusion
Deploying a RESTful API shouldn't be hectic and cyclic.sh has made sure deploying your backend code to the cloud is a simple as possible.

If you find any difficulty in the deployment process, you can reach out to the cyclic.sh team on discord.

Do well to follow me on Twitter and LinkedIn to connect.

originally publish on medium.com

๐Ÿ’– ๐Ÿ’ช ๐Ÿ™… ๐Ÿšฉ

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related

ยฉ TheLazy.dev

About