Wrong Version Number Error with Https

CMK version: 2.0.0p18
OS version: Ubuntu 18.04

Error message:

curl -I -v https://172.16.13.170:1492/serverstatus/login.py
*   Trying 172.16.13.170...
* TCP_NODELAY set
* Connected to 172.16.13.170 (172.16.13.170) port 1492 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
*   CAfile: /etc/ssl/certs/ca-certificates.crt
  CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* error:1408F10B:SSL routines:ssl3_get_record:wrong version number
* stopped the pause stream!
* Closing connection 0
curl: (35) error:1408F10B:SSL routines:ssl3_get_record:wrong version number

I’m trying to set up https on my checkmk dashboard. I’m pretty new to the whole https/ssl thing, so I’m not sure if my setup is correct. I created a self-signed certificate for this. Then I followed the info in the documentation: https://docs.checkmk.com/latest/en/omd_https.html. When I cURL on the Checkmk login page, I get an error about ssl3 wrong version number. However, when I run the same cURL command on the IP address alone, I think I get a good output:

curl -I -v https://172.16.13.170
* Rebuilt URL to: https://172.16.13.170/
*   Trying 172.16.13.170...
* TCP_NODELAY set
* Connected to 172.16.13.170 (172.16.13.170) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
*   CAfile: /etc/ssl/certs/ca-certificates.crt
  CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Unknown (8):
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Certificate (11):
* TLSv1.3 (OUT), TLS alert, Server hello (2):
* SSL certificate problem: self signed certificate
* stopped the pause stream!
* Closing connection 0
curl: (60) SSL certificate problem: self signed certificate
More details here: https://curl.haxx.se/docs/sslcerts.html

curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn more about this situation and
how to fix it, please visit the web page mentioned above.