Skip to content

Commit

Permalink
chore: bump proxy version in examples (#2254)
Browse files Browse the repository at this point in the history
  • Loading branch information
jackwotherspoon authored Jun 17, 2024
1 parent 757c08f commit a74fbf7
Show file tree
Hide file tree
Showing 9 changed files with 24 additions and 15 deletions.
15 changes: 9 additions & 6 deletions .github/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,16 @@
handleGHRelease: true
packageName: cloud-sql-proxy
releaseType: simple
versionFile: 'cmd/version.txt'
versionFile: "cmd/version.txt"
branches:
- branch: v1
versionFile: 'proxy/util/version.txt'
handleGHRelease: true
packageName: cloud-sql-proxy
releaseType: simple
- branch: v1
versionFile: "proxy/util/version.txt"
handleGHRelease: true
packageName: cloud-sql-proxy
releaseType: simple
extraFiles:
- README.md
- cmd/root.go
- examples/k8s-health-check/README.md
- examples/k8s-service/README.md
- examples/k8s-sidecar/README.md
5 changes: 3 additions & 2 deletions examples/k8s-health-check/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,18 +162,18 @@ readinessProbe:
successThreshold: 1
```
A web application has a database connection pool leak and the
engineering team can't find the root cause. To keep the system running,
the application should be automatically restarted if it consumes 50 connections
for more than 1 minute.
<!-- {x-release-please-start-version} -->
```yaml
containers:
- name: my-application
image: gcr.io/my-container/my-application:1.1
- name: cloud-sql-proxy
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.8.0
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.11.4
args:
# Set the --max-connections flag to 50
- "--max-connections"
Expand All @@ -192,3 +192,4 @@ for more than 1 minute.
timeoutSeconds: 5
successThreshold: 1
```
<!-- {x-release-please-end} -->
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ spec:
- name: cloud-sql-proxy
# It is recommended to use the latest version of the Cloud SQL Auth Proxy
# Make sure to update on a regular schedule!
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.8.0
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.11.4
imagePullPolicy: IfNotPresent

args:
Expand Down
4 changes: 3 additions & 1 deletion examples/k8s-service/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,16 +169,18 @@ For the PgBouncer deployment, we add the proxy as a sidecar, starting it on port

> [`pgbouncer_deployment.yaml`](pgbouncer_deployment.yaml#L70-L76)

<!-- {x-release-please-start-version} -->
``` yaml
- name: cloud-sql-proxy
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.8.0 # make sure to use the latest version
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.11.4 # make sure to use the latest version
args:
# Replace DB_PORT with the port the proxy should listen on
- "--port=<DB_PORT>"
- "<INSTANCE_CONNECTION_NAME>"
securityContext:
runAsNonRoot: true
```
<!-- {x-release-please-end} -->

Next, we create a PgBouncer service, listening on port 5342:

Expand Down
2 changes: 1 addition & 1 deletion examples/k8s-service/pgbouncer_deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ spec:
- name: cloud-sql-proxy
# It is recommended to use the latest version of the Cloud SQL Auth Proxy
# Make sure to update on a regular schedule!
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.8.0
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.11.4
args:
- "--port=5431"
- "<INSTANCE_CONNECTION_NAME>"
Expand Down
5 changes: 4 additions & 1 deletion examples/k8s-sidecar/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,14 @@ as a separate service for several reasons:
accurately scope and request resources to match your applications as it
scales
<!-- {x-release-please-start-version} -->
1. Add the Cloud SQL Auth Proxy to the pod configuration under `containers`:
> [proxy_with_workload-identity.yaml](proxy_with_workload_identity.yaml#L39-L69)
```yaml
- name: cloud-sql-proxy
# It is recommended to use the latest version of the Cloud SQL Auth Proxy
# Make sure to update on a regular schedule!
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.8.0 # make sure to use the latest version
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.11.4 # make sure to use the latest version
args:
# If connecting from a VPC-native GKE cluster, you can use the
# following flag to have the proxy connect over private IP
Expand All @@ -209,6 +210,8 @@ as a separate service for several reasons:
# application's requirements.
cpu: "1"
```
<!-- {x-release-please-end} -->
If you are using a service account key, specify your secret volume and add
the `--credentials-file` flag to the command:
Expand Down
2 changes: 1 addition & 1 deletion examples/k8s-sidecar/job_with_shutdown_hook.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ spec:
- name: cloud-sql-proxy
# It is recommended to use the latest version of the Cloud SQL Auth Proxy
# Make sure to update on a regular schedule!
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.8.0
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.11.4
args:
# Enable the admin api server on port 9091
- "--admin-port=9091"
Expand Down
2 changes: 1 addition & 1 deletion examples/k8s-sidecar/proxy_with_sa_key.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ spec:
- name: cloud-sql-proxy
# It is recommended to use the latest version of the Cloud SQL Auth Proxy
# Make sure to update on a regular schedule!
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.8.0
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.11.4
args:
# If connecting from a VPC-native GKE cluster, you can use the
# following flag to have the proxy connect over private IP
Expand Down
2 changes: 1 addition & 1 deletion examples/k8s-sidecar/proxy_with_workload_identity.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ spec:
- name: cloud-sql-proxy
# It is recommended to use the latest version of the Cloud SQL Auth Proxy
# Make sure to update on a regular schedule!
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.8.0
image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.11.4
args:
# If connecting from a VPC-native GKE cluster, you can use the
# following flag to have the proxy connect over private IP
Expand Down

0 comments on commit a74fbf7

Please sign in to comment.