Fleet-server: http: server gave HTTP response to HTTPS client

I am using my Elastic in a single deployment on Ubuntu on prem.
I used a script to automate the install like I always did but know since 7.17 I am no longer able to enroll via this process. Or by manual process as well from Kibana dashboard script.

username='elastic'
certIP='172.16.100.6'
fleetIP='172.16.100.6'
token='Y2hzdzRIOEJBSU80Mmo3R2hKdzM6V1B2UWxOTHdTRENmTFFrZ013Rk5xdw=='

## Download the cert and add the the shared certs directory
# scp <username>@<Server IP>:<filename i.e. ca.crt> .
# mv ca.crt /usr/local/share/ca-certificates/
# OR #
scp $username@$certIP:/ca.crt /usr/local/share/ca-certificates/

## Add the cert
update-ca-certificates

## Download and install the tarball image
curl -L -O https://artifacts.elastic.co/downloads/beats/elastic-agent/elastic-agent-7.17.1-linux-x86_64.tar.gz
tar xzvf elastic-agent-7.17.1-linux-x86_64.tar.gz

## Since the agent was installed via apt we just need to enroll with the Fleet Server
cd elastic-agent-7.17.1-linux-x86_64
./elastic-agent install -f --url=https://$fleetIP:8220 --insecure --enrollment-token=$token

## Restart and enable the service
systemctl start elastic-agent.service
systemctl enable elastic-agent.service

cd ..
rm -rf elastic*