-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.env.example
19 lines (16 loc) · 939 Bytes
/
.env.example
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
DATABASE_URL=mysql://<user>:<password>@<host>:<port>/<name>
# Example 1: Connect to TiDB Self-Hosted cluster
# DATABASE_URL=mysql://root@localhost:4000/test
# Example 2: Connect to TiDB Serverless cluster
#
# **TLS connection is required for Public Endpoint.**
# To enable TLS (SSL) connection, add the parameter `?sslaccept=strict` to the connection string.
#
# DATABASE_URL=mysql://talent_id.root:[email protected]:4000/test?sslaccept=strict
# Example 3: Connect to TiDB Dedicated cluster
#
# **TLS connection is optional but recommened for Public Endpoint.**
# To enable TLS (SSL) connection when connecting, you need to add the parameter `?sslaccept=strict` to the connection string,
# and specify the file path of the CA certificate via `&sslcert=/path/to/ca.pem`.
#
# DATABASE_URL=mysql://root:[email protected]_name.clusters.tidb-cloud.com:4000/test?sslaccept=strict&sslcert=/path/to/ca.pem