DevOps ++ (2/5)

Hello again, its been a weird long weekend and right now it seems like I’m getting sick again. But a different kind of sickness, probably a virus. I will keep you tuned about that.

Today’s music:

In this second part of the series of activities of DevOps we will start working with our enviroment and preparing the necesary tools for a software testing and quality focus. As I already told you in the first part, my current and only OS available is linux, guess it’s the perfect time for getting use to it and it’s tools. I will guide you to the steps I followed and the final status of this part.

BASE OS

Resultado de imagen para ubuntu

First of all, we need a linux machine, it can be the host OS or a virtual machine, as you wish. In my case I have installed  UBUNTU 18.04. You can download the 18.04 version on https://www.ubuntu.com/download/desktop and if you need a virtual machine I really recommend you to use virtual box. It has been my virtualization software since I was in highschool (7 years at least). And you can download it from: https://www.virtualbox.org/wiki/Downloads

LANGUAGE ENVIROMENT

Resultado de imagen para python

What its next, we need to add support to our coding language. In my case Python 3.6 which you can install with:

$ sudo apt install python3-minimal

Simple right? (for more info look at https://linuxconfig.org/how-to-install-python-in-ubuntu-18-04-bionic-beaver-linux)

GIT

Resultado de imagen para git

Well, after we have our language, we need to install git on our linux distribution. For that we only need to put the next command in the terminal:

As it it always recommended, we start with the OS and package updates.

$ sudo apt-get update

Next goes git

$ apt-get install git-core

And to verify that  it is correctly installed we look at the installed version with:

$ git --version

Which should output something like:

$ git version 3.6

(For more info. about git on linux go to: https://www.liquidweb.com/kb/install-git-ubuntu-16-04-lts/)

Web Deployment

I chose to use nodejs since its a js engine developed by Google, famous and powerful but I have never had the chance of working hardcore on it and think this is the perfect opportunity for it.

First lets start with nodejs. I looked for some tutorials but keep crushing into issues while trying the instalation command to I simply tried with:

$ sudo apt install nodejs

and then

sudo apt install npm

Guess what? It worked like a charm so I don’t see why you would have issues with this commands. You can always verify the installation with:

$ nodejs -v
$ npm -v

I already told you i’m not really familiar with this kind of tools so I decided to go on a noobs tutorial for the basics. I recommend you this tutorial where at the end, you end up with a server deployed on the port you defined. This will help us in the future.

CRON

And finally we will need to setup this tool called CRON. This helps us for automation purposes and the next part. It works by setting custom processes and activities scheduled for their execution in linux.

Again we need to to de updates and upgrade for our server by doing

$ sudo apt-get update
$ sudo apt-get upgrade

To know if we have the package installed we use the next command:

$ dpkg -l cron

If we don’t have it, we just use:

$ sudo apt-get install cron

And verify that the service is running with

$ systemctl status cron

In order to set new jobs for cron, you can look how in the next link:

https://www.rosehosting.com/blog/ubuntu-crontab/

Deja un comentario