This guide establishes a method to successfully install a docker application on OMV.
Introduction and basic concepts
Docker is a technology that enables the creation and use of Linux containers. A container is a closed environment where one or more applications and their dependencies are installed, grouped and isolated from each other, running on the same operating system kernel.
Docker allows you to install, uninstall, modify, update applications as many times as you want without causing damage to the system.
Starting from a system with OMV installed and with a file system with shared folders, to use Docker we need::
in our file system to store the containers. The recommendation is to
dedicate an SSD disk, independent
of the operating system,
with EXT4 format, of at least 60GB. Speed will be achieved in the
applications, avoiding docker incompatibilities with special file
systems and completely removing the applications from the system
disk. In this space, PROGRAM FILES and CONFIGURATION FILES will be
- They are expendable files.
- We will store them in the docker folder of the SSD disk.
- Docker takes care of downloading these files from the internet and configuring them automatically.
- Docker containers are updated by downloading the latest version of these files and replacing the old one. There are some exceptions, consult the documentation of each application you install to know how it works.
- They are irreplaceable files.
- We will store them in the config folder of the SSD disk.
- They are created, modified and personalized during the operation of the application with passwords, personal settings, databases, etc. depending on the case.
- We must keep them if we want to keep the application in the same state or restore it after an OMV reinstall. It is a good idea to make regular backups of this folder.
- PROGRAM FILES:
who will be in charge of executing the container.
- Docker applications execute the actions on the system from the container by means of a user. So the permissions of this user will be the permissions that the application will have. This will be the control mechanism to prevent the application from doing anything on our system..
- For security, it is convenient to create a user and grant only the necessary permissions for the application to work. In this guide this user is called appuser.
- Applications need to write to the docker and config folders. The way to give permissions to the application is to give them to the user who executes it. Therefore we must give write permissions to appuser in these folders. Also if we want the app to use any data from our shared folders, appuser must also have access to those folders.