How do we create a remote repository in Artifactory as a mirror to nvidia-docker?

Subject

How do we create a remote repository in Artifactory as a mirror to nvidia-docker?

Description

In case you wish to work with Nvidia container runtime for Docker and to cache artifacts using Artifactory, this article will guide you on how to set this up.

Resolution
 

Nvidia repository works different from a regular Artifactory Debian repository.
In order to work against Nvidia-docker, you need to create a remote repository for every individual repository in Nvidia-docker.
For example, in order to work with the following:
“deb https://nvidia.github.io/nvidia-container-runtime/ubuntu16.04/$(ARCH)/”:
  1. Create remote debian repository and set the URL: https://nvidia.github.io/nvidia-container-runtime/
  2. You need to update the nvidia-docker.list file located in /etc/apt/nvidia-docker.list to the following:
    1. deb https://user:password@artifactory-url/artifactory/nvidia-container-runtime/ubuntu16.04/$(ARCH) /
  3. Sudo apt update
Repeat the above steps for the rest of the repositories you need
In every repository in Artifactory the URL should look like the following: