• Stan Lagun's avatar
    Support for https for etcd connection · 0b870d18
    Stan Lagun authored
    This commit adds ability to use TLS transport for etcd.
    New logic is applied when the etcd URL has https:// scheme.
    TLS parameters are passed in the environment variables:
    
    ETCD_CA_FILE - path to CA certificate. If not specified, then
    system-provided certificates are used.
    
    ETCD_CERT_FILE - client certificate
    ETCD_KEY_FILE - client key file
    - either both of none of this two must be specified
    
    ETCD_TLS_SERVER_NAME - expected CN of the certificate. Useful when
    URL points to a different domain from that in server certificate
    
    ETCD_TLS_INSECURE - if set to "1" (or "true" or "yes") makes client
    bypass server certificate validation.
    
    Also for unification with other providers and rest of connection
    settings, etcd URL is no longer specified in the command line, but
    rather in ETCD_URLS environment variable (defaults to
    http://localhost:2379). More than one comma-separated URL can be
    specified. All of the URLs must start with either http:// or https://
    
    Also, now it possible to communicate with etcd through proxy specified
    in standard environment variables
    0b870d18