Try adding TrustServerCertificate=True to the connection string, as per This StackOverflow post
2022 Update:
The linked post has been updated with more up to date recommendations. The answer posted here is a stopgap, and not recommended for production workloads