grafana / oncall

Developer-friendly incident response with brilliant Slack integration
GNU Affero General Public License v3.0
3.51k stars 291 forks source link

External mysqldb with require_secure_transport=ON fails on wait-for-db #416

Open vsmanu opened 2 years ago

vsmanu commented 2 years ago

If we use an external mysql db with require_secure_transport=ON , the container "wait-for-db" fails with the following stack trace, even for well-known CAs.

File "/usr/local/lib/python3.9/site-packages/django/db/backends/base/base.py", line 200, in connect self.connection = self.get_new_connection(conn_params) File "/usr/local/lib/python3.9/site-packages/django/utils/asyncio.py", line 33, in inner return func(*args, **kwargs) File "/usr/local/lib/python3.9/site-packages/django/db/backends/mysql/base.py", line 234, in get_new_connection connection = Database.connect(**conn_params) File "/usr/local/lib/python3.9/site-packages/pymysql/connections.py", line 353, in __init__ self.connect() File "/usr/local/lib/python3.9/site-packages/pymysql/connections.py", line 633, in connect self._request_authentication() File "/usr/local/lib/python3.9/site-packages/pymysql/connections.py", line 907, in _request_authentication auth_packet = self._read_packet() File "/usr/local/lib/python3.9/site-packages/pymysql/connections.py", line 725, in _read_packet packet.raise_for_error() File "/usr/local/lib/python3.9/site-packages/pymysql/protocol.py", line 221, in raise_for_error err.raise_mysql_exception(self._data) File "/usr/local/lib/python3.9/site-packages/pymysql/err.py", line 143, in raise_mysql_exception raise errorclass(errno, errval) django.db.utils.OperationalError: (3159, 'Connections using insecure transport are prohibited while --require_secure_transport=ON.'

Expected behaviour:

github-actions[bot] commented 8 months ago

This issue has been automatically marked as stale because it has not had activity in the last 120 days.

github-actions[bot] commented 1 month ago

This issue has been automatically marked as stale because it has not had activity in the last 120 days.