You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To deploy the application to Cloud Functions, first fill in the values for required environment variables in `.env.yaml`. Then run the following command
To deploy the application to Cloud Functions, first fill in the values for required environment variables in `.env.yaml`. Then run the following command
Copy file name to clipboardExpand all lines: cloud-sql/sqlserver/servlet/README.md
+46-1Lines changed: 46 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -31,6 +31,34 @@ export DB_NAME='my_db'
31
31
Note: Saving credentials in environment variables is convenient, but not secure - consider a more
32
32
secure solution such as [Cloud KMS](https://cloud.google.com/kms/) or [Secret Manager](https://cloud.google.com/secret-manager/) to help keep secrets safe.
33
33
34
+
## Configure SSL Certificates
35
+
For deployments that connect directly to a Cloud SQL instance with TCP,
36
+
without using the Cloud SQL Proxy,
37
+
configuring SSL certificates will ensure the connection is encrypted.
38
+
1. Use the gcloud CLI to [download the server certificate](https://cloud.google.com/sql/docs/mysql/configure-ssl-instance#server-certs) for your Cloud SQL instance.
39
+
- Get information about the service certificate:
40
+
```
41
+
gcloud beta sql ssl server-ca-certs list --instance=INSTANCE_NAME
- Download the certificate information to a local PEM file
48
+
```
49
+
gcloud beta sql ssl server-ca-certs list \
50
+
--format="value(cert)" \
51
+
--instance=INSTANCE_NAME > \
52
+
server-ca.pem
53
+
```
54
+
55
+
1. [Import the server certificate into a custom Java truststore](https://dev.mysql.com/doc/connector-j/8.0/en/connector-j-reference-using-ssl.html) using `keytool`:
For more details about using Cloud Run see http://cloud.run.
126
160
Review other [Java on Cloud Run samples](../../../run/).
127
161
162
+
### Deploy to Google Cloud Functions
163
+
164
+
To deploy the application to Cloud Functions, first fill in the values for required environment variables in `.env.yaml`. Then run the following command
To avoid incurring any charges, navigate to your project's [App Engine settings](https://console.cloud.google.com/appengine/settings) and click `Disable Application`. Also [delete your Cloud SQL Instance](https://cloud.google.com/sql/docs/mysql/delete-instance) if you no longer need it.
0 commit comments