static getHttpsAgentOptions(dockerType, url) {
        let baseOptions = {
            maxCachedSessions: 0,
            rejectUnauthorized: true
        };
        let certOptions = {};

        let dirName = (new URL(url)).hostname;

        let caPath = path.join(Database.dockerTLSDir, dirName, DockerHost.CertificateFileNameCA);
        let certPath = path.join(Database.dockerTLSDir, dirName, DockerHost.CertificateFileNameCert);
        let keyPath = path.join(Database.dockerTLSDir, dirName, DockerHost.CertificateFileNameKey);

        if (dockerType === "tcp" && fs.existsSync(caPath) && fs.existsSync(certPath) && fs.existsSync(keyPath)) {
            let ca = fs.readFileSync(caPath);
            let key = fs.readFileSync(keyPath);
            let cert = fs.readFileSync(certPath);
            certOptions = {
                ca,
                key,
                cert
            };
        }

        return {
            ...baseOptions,
            ...certOptions
        };
    }
Returns HTTPS agent options with client side TLS parameters if certificate files
for the given host are available under a predefined directory path.

The base path where certificates are looked for can be set with the
'DOCKER_TLS_DIR_PATH' environmental variable or defaults to 'data/docker-tls/'.

If a directory in this path exists with a name matching the FQDN of the docker host
(e.g. the FQDN of 'https://example.com:2376' is 'example.com' so the directory
'data/docker-tls/example.com/' would be searched for certificate files),
then 'ca.pem', 'key.pem' and 'cert.pem' files are included in the agent options.
File names can also be overridden via 'DOCKER_TLS_FILE_NAME_(CA|KEY|CERT)'.
@param {string} dockerType i.e. "tcp" or "socket"
@param {string} url The docker host URL rewritten to https://
@returns {object} HTTP agent options