Commit 405918f 1 parent 4b56798 commit 405918f Copy full SHA for 405918f
File tree 1 file changed +4
-5
lines changed
kubernetes_engine/django_tutorial
1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -65,10 +65,13 @@ spec:
65
65
key : password
66
66
ports :
67
67
- containerPort : 8080
68
-
68
+ initContainers :
69
69
- image : gcr.io/cloud-sql-connectors/cloud-sql-proxy:latest
70
70
name : cloud-sql-proxy
71
71
args :
72
+ # If connecting from a VPC-native GKE cluster, you can use the
73
+ # following flag to have the proxy connect over private IP
74
+ # - "--private-ip"
72
75
- " --port=5432"
73
76
- " --credentials-file=/secrets/cloudsql/credentials.json"
74
77
- " <your-cloudsql-connection-string>"
@@ -78,17 +81,13 @@ spec:
78
81
readOnly : true
79
82
- name : ssl-certs
80
83
mountPath : /etc/ssl/certs
81
- - name : cloudsql
82
- mountPath : /cloudsql
83
84
volumes :
84
85
- name : cloudsql-oauth-credentials
85
86
secret :
86
87
secretName : cloudsql-oauth-credentials
87
88
- name : ssl-certs
88
89
hostPath :
89
90
path : /etc/ssl/certs
90
- - name : cloudsql
91
- emptyDir : {}
92
91
# [END gke_kubernetes_deployment_yaml_python]
93
92
---
94
93
# [START gke_kubernetes_service_yaml_python]
You can’t perform that action at this time.
0 commit comments