Inventing the next Harvard

Harvard excels in education quality, as a nexus for research, a pipeline for Nobel Prizes, a career jumping-off point for its undergraduate degree holders. It boasts the largest endowment and a…

Smartphone

独家优惠奖金 100% 高达 1 BTC + 180 免费旋转




Deploying your Node.js Application on IBM Cloud

Prerequisites:

I am a software engineer, and a Blockchain enthusiast, originally from Tunisia. I have a master degree in IT Engineering and I’ve been working with IBM Cloud for about a year.

IBM effectively entered to the cloud market in 2009. Since then, IBM constantly evolved its products to continue meeting its partners and clients needs. As a cloud developer, I have many reasons to use IBM Cloud. First of all, IBM Cloud offers an end to end catalog of products and services that offer all what you need to build modern applications. You can find databases, AI, security, orchestration, Internet of Things, Blockchain and much more. Second, IBM Cloud is very aligned with DevOps methodology, providing a complete set of services for continuous software delivery enabling developers to focus on innovation while accelerating the delivery process. Third, if you are an application developer, you often need to deploy and test. IBM Cloud offers a variety of deployment options, from a simple Cloud Foundry push command to a customized Deployment Pipeline.

After the small introduction to IBM Cloud from a developer perspective, let’s move directly to the serious talking. So, to briefly describe what this article is about, we will create a simple node.js/express application, add it to GitHub, create a delivery pipeline, and deploy our application.

So, to make all the focus on the application delivery process, I want to skip the parts where we create the node.js/express application and we add it to GitHub.

I put here some useful articles that explain how to create node.js/express application and how to add a repository to GitHub:

First off, let me put the link to our “Hello World” application git repository because we’ll deploy the application through the repository.

Once you log in to IBM Cloud, jump to the Catalog and look for “Toolchain”.

Go to Toolchain and choose “Develop a Cloud Foundry app” template.

In the config page that appears, you can create a customized Toolchain Name as long as it is unique, select the region and a resource group. In the “Select a source provider” scrolling list, choose “GitHub”. Then, go down and click on “Authorize”.

Click on Authorize IBM-Cloud .

Once you get authorized, choose “Existing” option in “Repository type:”, and paste the repository URL in “Repository URL:”

Next, go to the Delivery Pipeline. You can choose a different “App name”, and you need to put an existing “IBM Cloud API key” or create a new one. This will allow the application to access the IBM Cloud Runtime.

Finally, confirm your configuration by hitting “Create”. If everything goes as expected, you’ll have a screen with your Toolchain template running. IBM Cloud offers multiple tools that supports developers throughout their innovation journey. You can track issues posted by you app users. Also, you have “Eclipse Orion Web IDE” to edit and debug your code. Besides, you have a configurable Delivery Pipeline tool. Finally, the DevOps Insight helps you track your build and deployment jobs, with quality metrics.

Let’s go to Delivery Pipeline and see what we find.

By default, there is two stages in the template that we used, but you can always add or delete stages according to your needs. You can also configure the “JOBS” inside each stage.

But for the sake of this tutorial, we will let the configuration as it is.

So once the deploy stage passes, you can check if your application is up and running. To do so, click on the Navigation Menu on the upper left, then jump to “Resource List”.

Under “Cloud Foundry apps”, you should find the application you’ve just deployed.

When you enter to your application, you’ll find details about the instance health, allocated resources, and runtime cost. You will be able to customize the number of instances, and the allocated memory for each instance.

To test your application, you can go to “Details”, and go to the URL under “Routes”.

And here is the final result!

Here what we discussed today:

Thanks to Maryline Harvey for her contribution!

Add a comment

Related posts:

Why your dad tells you to stay away from stocks

Learn about why most people think stock markets are risky and how you can reduce the risk of your investments in this simple, fun, and engaging article.

Of The Number

Judas Iscariot was one of the twelve. One of the closest members of a class of men to know the Lord. Judas Iscariot, being of the twelve, watched more of Jesus’s miracles than almost anyone else…

Fighting from the Heart for a World Free of Hate

Maybe there was something to unpack in the realization that I found comfort in the physical representation of the concept that had held me captive for too many years. Regardless, in the moment of…