How To Install ruby-docker-api on Debian 9

In this tutorial we learn how to install ruby-docker-api on Debian 9. ruby-docker-api is Ruby gem to interact with docker.io remote API

Introduction

In this tutorial we learn how to install ruby-docker-api on Debian 9.

What is ruby-docker-api

ruby-docker-api is:

ruby-docker-api gem provides an object-oriented interface to the Docker Remote API and a complete client implementation.

ruby-docker-api is designed to be very lightweight. Almost no state is cached (aside from id’s which are immutable) to ensure that each method call’s information is up to date. As such, just about every external method represents an API call.

There are three methods to install ruby-docker-api on Debian 9. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install ruby-docker-api Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install ruby-docker-api using apt-get by running the following command:

sudo apt-get -y install ruby-docker-api

Install ruby-docker-api Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install ruby-docker-api using apt by running the following command:

sudo apt -y install ruby-docker-api

Install ruby-docker-api Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Debian. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install ruby-docker-api using aptitude by running the following command:

sudo aptitude -y install ruby-docker-api

How To Uninstall ruby-docker-api on Debian 9

To uninstall only the ruby-docker-api package we can use the following command:

sudo apt-get remove ruby-docker-api

Uninstall ruby-docker-api And Its Dependencies

To uninstall ruby-docker-api and its dependencies that are no longer needed by Debian 9, we can use the command below:

sudo apt-get -y autoremove ruby-docker-api

Remove ruby-docker-api Configurations and Data

To remove ruby-docker-api configuration and data from Debian 9 we can use the following command:

sudo apt-get -y purge ruby-docker-api

Remove ruby-docker-api configuration, data, and all of its dependencies

We can use the following command to remove ruby-docker-api configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge ruby-docker-api

Dependencies

ruby-docker-api have the following dependencies:

References

Summary

In this tutorial we learn how to install ruby-docker-api package on Debian 9 using different package management tools: apt, apt-get and aptitude.