How To Install Git on Ubuntu 18.04


Step 1 — Update Default Packages

Logged into your Ubuntu 18.04 server as a sudo non-root user, first update your default packages.

  • sudo apt update

Step 2 — Install Git

  • sudo apt install git

Step 3 — Confirm Successful Installation

You can confirm that you have installed Git correctly by running this command and receiving output similar to the following:

  • git –version
Output
git version 2.17.1

How to install Ansible


 

root@aryan-VirtualBox:~# apt-add-repository ppa:ansible/ansible
Ansible is a radically simple IT automation platform that makes your applications and systems easier to deploy. Avoid writing scripts or custom code to deploy and update your applications— automate in a language that approaches plain English, using SSH, with no agents to install on remote systems.

http://ansible.com/
More info: https://launchpad.net/~ansible/+archive/ubuntu/ansible
Press [ENTER] to continue or Ctrl-c to cancel adding it.

Hit:1 http://ca.archive.ubuntu.com/ubuntu bionic InRelease
Get:2 http://ca.archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]
Get:3 http://ca.archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB]

 

root@aryan-VirtualBox:~# apt-get install ansible
Reading package lists… Done
Building dependency tree
Reading state information… Done
The following additional packages will be installed:
python-httplib2 python-jinja2 python-markupsafe python-paramiko
python-pyasn1 python-yaml sshpass
Suggested packages:
python-jinja2-doc python-gssapi
The following NEW packages will be installed:
ansible python-httplib2 python-jinja2 python-markupsafe python-paramiko
python-pyasn1 python-yaml sshpass
0 upgraded, 8 newly installed, 0 to remove and 10 not upgraded.
Need to get 4,369 kB of archives.
After this operation, 36.7 MB of additional disk space will be used.
Do you want to continue? [Y/n]

provider.docker: Error pinging Docker server: Got permission denied while trying to connect to the Docker daemon socket


provider.docker: Error pinging Docker server: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/_ping: dial unix /var/run/docker.sock: connect: permission denied

 

aryan@aryan-VirtualBox:~/docker$ terraform plan
Refreshing Terraform state in-memory prior to plan…
The refreshed state will be used to calculate this plan, but will not be
persisted to local or remote state storage.
————————————————————————

Error: Error running plan: 1 error(s) occurred:

* provider.docker: Error pinging Docker server: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/_ping: dial unix /var/run/docker.sock: connect: permission denied
aryan@aryan-VirtualBox:~/docker$

try it with sudo command

aryan@aryan-VirtualBox:~/docker$ sudo terraform apply

An execution plan has been generated and is shown below.
Resource actions are indicated with the following symbols:
+ create

Terraform will perform the following actions:

+ docker_image.image_id
id: <computed>
latest: <computed>
name: “ghost:latest”
Plan: 1 to add, 0 to change, 0 to destroy.

Do you want to perform these actions?
Terraform will perform the actions described above.
Only ‘yes’ will be accepted to approve.

Enter a value: yes

docker_image.image_id: Creating…
latest: “” => “<computed>”
name: “” => “ghost:latest”
docker_image.image_id: Still creating… (10s elapsed)
docker_image.image_id: Still creating… (20s elapsed)
docker_image.image_id: Creation complete after 20s (ID: sha256:f32905852788d222be7b05357a906cf9…2f50b7cea5a0ecf229d892d9d9ghost:latest)

Apply complete! Resources: 1 added, 0 changed, 0 destroyed.
aryan@aryan-VirtualBox:~/docker$

Steps to install terraform on Ubuntu / Ubuntu cloud server :


  1. Install unzip
    sudo apt-get install unzip
    
  2. Download latest version of the terraform
    wget https://releases.hashicorp.com/terraform/0.11.13/terraform_0.11.13_linux_amd64.zip
    
  3. Extract the downloaded file archive
    unzip terraform_0.11.13_linux_amd64.zip
    
  4. Move the executable into a directory searched for executables
    sudo mv terraform /usr/local/bin/
    
  5. Run it
    terraform --version

 

aryan@aryan-VirtualBox:~$ sudo apt-get install unzip
[sudo] password for aryan:
Reading package lists… Done
Building dependency tree
Reading state information… Done
unzip is already the newest version (6.0-21ubuntu1).
0 upgraded, 0 newly installed, 0 to remove and 5 not upgraded.
aryan@aryan-VirtualBox:~$ wget https://releases.hashicorp.com/terraform/0.11.13/terraform_0.11.13_linux_amd64.zip
–2019-05-03 11:59:38– https://releases.hashicorp.com/terraform/0.11.13/terraform_0.11.13_linux_amd64.zip
Resolving releases.hashicorp.com (releases.hashicorp.com)… 151.101.1.183, 151.101.193.183, 151.101.129.183, …
Connecting to releases.hashicorp.com (releases.hashicorp.com)|151.101.1.183|:443… connected.
HTTP request sent, awaiting response… 200 OK
Length: 21128942 (20M) [application/zip]
Saving to: ‘terraform_0.11.13_linux_amd64.zip’

terraform_0.11.13_l 100%[===================>] 20.15M 69.3MB/s in 0.3s

2019-05-03 11:59:38 (69.3 MB/s) – ‘terraform_0.11.13_linux_amd64.zip’ saved [21128942/21128942]

aryan@aryan-VirtualBox:~$ unzip terraform_0.11.13_linux_amd64.zip
Archive: terraform_0.11.13_linux_amd64.zip
inflating: terraform
aryan@aryan-VirtualBox:~$ sudo mv terraform /usr/local/bin/
aryan@aryan-VirtualBox:~$ terraform –version
Terraform v0.11.13

How To Install and Configure Redis on Ubuntu 16.04


Introduction

Redis is an in-memory key-value store known for its flexibility, performance, and wide language support. In this guide, we will demonstrate how to install and configure Redis on an Ubuntu 16.04 server.

Prerequisites

To complete this guide, you will need access to an Ubuntu 16.04 server. You will need a non-root user withsudo privileges to perform the administrative functions required for this process. You can learn how to set up an account with these privileges by following our Ubuntu 16.04 initial server setup guide.

When you are ready to begin, log in to your Ubuntu 16.04 server with your sudo user and continue below.

 

Read more about how to install and configure Redis on Ubuntu