-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug: postgrescluster listing would cause support export to fail fatally. This updates that to behave like our other K8s resouce-retrievals, i.e., fail gracefully by surfacing the error but continue. Issue: [PGO-821]
- Loading branch information
1 parent
3d1b0db
commit e1e8bb8
Showing
7 changed files
with
79 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
title: "0.4.1" | ||
draft: false | ||
weight: 996 | ||
--- | ||
|
||
[Crunchy Postgres for Kubernetes]: https://www.crunchydata.com/products/crunchy-postgresql-for-kubernetes | ||
[`pgo` CLI documentation]: https://access.crunchydata.com/documentation/postgres-operator-client/latest | ||
|
||
Crunchy Data announces the release of `pgo`, Postgres Operator Client from Crunchy Data 0.4.1. | ||
|
||
Built as a `kubectl` plugin, the `pgo` CLI facilitates the creation and management of PostgreSQL clusters created using [Crunchy Postgres for Kubernetes][]. | ||
|
||
For more information about using the CLI and the various commands available, please see the [`pgo` CLI documentation][]. | ||
|
||
Additionally, please see the [CPK documentation](https://access.crunchydata.com/documentation/postgres-operator/latest) for information about [getting started](https://access.crunchydata.com/documentation/postgres-operator/latest/quickstart/) with Crunchy Postgres for Kubernetes. | ||
|
||
## Bug | ||
- The `support export` command would fail fatally if the user didn't have permissions to list postgresclusters at the cluster-scope. This release fixes that so our postgrescluster list fails gracefully (like our other atttempts to gather Kubernetes resources). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,4 +15,4 @@ | |
package cmd | ||
|
||
// store the current PGO CLI version | ||
const clientVersion = "v0.4.0" | ||
const clientVersion = "v0.4.1" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
## The support export command | ||
|
||
### What is it for? | ||
|
||
The `support export` command is meant to give users a simple command to run that will produce a tar file of information that they can then use to debug or send to Crunchy Data to debug. | ||
|
||
### What are its invariants? | ||
|
||
#### Only work on one cluster at a time | ||
|
||
If the cluster doesn't exist, exit without creating a tar. | ||
|
||
#### Fail gracefully when forbidden from retrieving K8s API info | ||
|
||
If we run into an error getting info for part X, move on to part Y, Z, et al. _while_ also surfacing the error. | ||
|
||
### What does it do (in order)? | ||
|
||
* Check postgrescluster exists (fail hard) | ||
* Create output tar file & defer close | ||
* Gather CLI version (from code) | ||
* Get all postgrescluster names | ||
* Get Kubernetes context (fail hard) | ||
* Get server version (fail hard) | ||
* Gather node info | ||
* Gather namespace info | ||
* Write cluster spec (gotten in step 1) | ||
* Gather namespaced resources for cluster: | ||
* statefulsets | ||
* deployments | ||
* replicasets | ||
* jobs | ||
* cronjobs | ||
* poddisruptionbudgets | ||
* pods | ||
* persistentvolumeclaims | ||
* configmaps | ||
* services | ||
* endpoints | ||
* serviceaccounts | ||
* ingresses | ||
* limitranges | ||
* Gather events | ||
* Gather logs | ||
* Gather postgresql logs | ||
* Get monitoring logs | ||
* Gather patroni info | ||
* Gather pgBackRest info | ||
* Gather process info | ||
* Gather system time | ||
* Gather list of kubectl plugins |