DEV Community

Etornam🤴🏽🇬🇭
Etornam🤴🏽🇬🇭

Posted on • Updated on

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

Top comments (0)