How to setup Adonis.js on Ubuntu?


Cloud server hosting the latest form of hosting technology where every business is looking for. And today we can say that cloud server are instances of a Virtual Machine running in a hypervisor environment managed by HostingRaja. The cloud infrastructure is composed of numerous servers which are stored in the data center, and in the Linux cloud server, it uses its power and flexibility to replace your business needs which are required to maintain the on-premise software applications. And today one of the biggest advantages of using cloud server hosting is that you can access your data at any time at any place via the internet.

 

And today using a cloud server for your business gives you more advantages which help you and your business to grow. Using a cloud server for your business always gives you better security, scalability, reliability, and flexibility. So today if you are using a cloud server for your website and if you are looking for a piece of information on how to setup Adonis.js on Ubuntu 14 on your Linux cloud server then here is the complete solution on it. So what is Adonis.js? Adonis.js is an MVC Framework for NodeJs which enables you to write web apps with less code. This Adonis.js concept borrows from another solid framework like Laravel and leverages ES6 to make the code more expressive and maintainable.

 

What is Adonis.js?

AdonisJs is basically a Node.js web framework which runs on all operating system. In Adonis.js it offers a stable eco-system where you can write on the server side web application so that you can focus on your business needs over settling on which package to choose or not. And in AdonisJs you also get API where it helps to build a full-stack web application or a micro API server. Adonis.js is a really good framework, for those who have a little knowledge of Node.js and is from a PHP (esp. Laravel background). So if you are into a folder structure then it is totally based on Laravel, with all the CLI to make models, controller, etc.

 

The reason why you should use  Adonis.Js is that AdonisJs pairs with a command: adonis install <package>, that is similar to: npm install or yarn add. This adonis install uses npm or yarn to install the package and also performs a more step after the install that is all providers can have two files instructions.js and instructions.md, that  are used to perform post install steps by adonis

Cloud Hosting Plans

MEDIUM CLOUD
9571 Save 44%
5360 / month
7.4 / hour
  • Disk Space : 80 GB SSD
  • 4 Core
  • RAM : 8 GB
  • Bandwidth : 5 TB
SMALL CLOUD
6929 Save 44%
3880 / month
5.3 / hour
  • Disk Space : 80 GB SSD
  • 2 Core
  • RAM : 6 GB
  • Bandwidth : 5 TB
MICRO CLOUD
4786 Save 44%
2680 / month
3.7 / hour
  • Disk Space : 60 GB SSD
  • 2 Core
  • RAM : 4 GB
  • Bandwidth : 4 TB
LARGE CLOUD
19214 Save 44%
10760 / month
14.9 / hour
  • Disk Space : 120 GB SSD
  • 8 Core
  • RAM : 16 GB
  • Bandwidth : 6 TB
EXTRA LARGE CLOUD
38286 Save 44%
21440 / month
29.7 / hour
  • Disk Space : 320 GB SSD
  • 12 Core
  • RAM : 32 GB
  • Bandwidth : 7 TB
NANO CLOUD
2545 Save 44%
1425 / month
1.9 / hour
  • Disk Space : 50 GB SSD
  • 2 Core
  • RAM : 2 GB
  • Bandwidth : 3 TB

Follow the below step to setup Adonis.js on Ubuntu on a cloud server:

 

Step 1: To Installation Ubuntu

Step 1.1: The command list of packages for all of your repositories and PPA’s and make sure it is up to date.

                    sudo apt -get update -y

Step 1.2: This command should be runned after the above it does an actual software upgrade of the update list

                             sudo apt-get upgrade -y

Step 1.3: execute the below command

                     sudo apt-get install -y curl git software-properties-common

 

Step 2: To install Nodejs

Step 2.1: curl -sL https://deb.nodesource.com/setup_5.x | sudo -E bash -sudo apt-get update

Step 2.2:sudo apt-get install -y nodejs

Or

You run the below commands to install Node.js from the NodeSource APT repository with a compiler so that we can install native add-ons from npm.

Step 2.1: sudo apt-get update
Step 2.2: sudo apt-get install -y curl apt-transport-https ca-certificates &&
 curl --fail -ssL -o setup-nodejs https://deb.nodesource.com/setup_8.9.4 &&
 sudo bash setup-nodejs &&
 sudo apt-get install -y nodejs build-essential

 

Step 3: Execute the below command to install Adonis.js

 

npm i --global @adonisjs/cli

Or

sudo npm install -g adonis-cli nodemon

 

Test your application: Now you have to create a test application



Step 1: Create a test application called "adonistest"

 

adonis new adonistest

 

Step 2: To start "adonistest" application

Step 2.1: change directory

               cd adonistest

Step 2.2: start the application

               npm start

You can also use --yarn instead of npm

 

Now you will see the below command prompt (if adonis.js is installed correctly )

> adonis-app@2.0.0 start /home/vagrant/adonistest

> node --harmony_proxies server.js

 

You can also test adonis.js using the following

Step 1: execute the following

                adonis new yardstick
Step 2: change directory

          cd yardstick
Step 3: to start the application

         adonis serve --dev

 

Note:

If need any help with the adonis.js commands, you can see the available list of options using the command

                    adonis new --help

 

If you need any assistance, feel free to contact our technical team members as they are available 24/7 via phone call, email, ticket system or call out toll-free no 1800-123-8642. We will be happy to help you.