@cryptotaxi247 / netdata-1 / commits / 9fe43430f

Fixed handling of TLS config so that cURL works in all cases. (#10491)

We should not be hard-coding the CA file or messing with cURL options to handle this, but should instead be relying on the config detected at setup time for the install to just get it right (as it will in 99% of cases).

Austin S. Hemmelgarn committed Jan 13, 2021 at 07:13 UTC 9fe43430f2a12a89a5f84c8cda43066272d1281d
2 files changed +1 -21
packaging/makeself/install-or-update.sh
-19
@@ -129,25 +129,6 @@ else
129 run_failed "I could not add group netdata, so no user netdata will be created as well. Netdata run as root:root"
130 fi
131
132 -# -----------------------------------------------------------------------------
133 -progress "Check SSL certificates paths"
134 -
135 -if [ ! -f "/etc/ssl/certs/ca-certificates.crt" ]; then
136 - if [ ! -f /opt/netdata/.curlrc ]; then
137 - cacert=
138 -
139 - # CentOS
140 - [ -f "/etc/ssl/certs/ca-bundle.crt" ] && cacert="/etc/ssl/certs/ca-bundle.crt"
141 -
142 - if [ -n "${cacert}" ]; then
143 - echo "Creating /opt/netdata/.curlrc with cacert=${cacert}"
144 - echo > /opt/netdata/.curlrc "cacert=${cacert}"
145 - else
146 - run_failed "Failed to find /etc/ssl/certs/ca-certificates.crt"
147 - fi
148 - fi
149 -fi
150 -
132 # -----------------------------------------------------------------------------
133 progress "Install logrotate configuration for netdata"
134
packaging/makeself/jobs/50-curl-7.73.0.install.sh
+1 -2
@@ -22,8 +22,7 @@ run ./configure \
22 --enable-proxy \
23 --enable-ipv6 \
24 --enable-cookies \
25 - --with-ca-fallback \
26 - --with-ca-bundle=/opt/netdata/etc/ssl/certs/ca-bundle.crt
25 + --with-ca-fallback
26
27 # Curl autoconf does not honour the curl_LDFLAGS environment variable
28 run sed -i -e "s/curl_LDFLAGS =/curl_LDFLAGS = -all-static/" src/Makefile