mirror of
https://github.com/cloudnative-pg/plugin-barman-cloud.git
synced 2026-09-06 23:12:21 +02:00
Compare commits
11 Commits
af45042d6e
...
473c44f092
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
473c44f092 | ||
|
|
c592966a4a | ||
|
|
173c6d622b | ||
|
|
3c273641e3 | ||
|
|
8af1fa77f8 | ||
|
|
7bf9c6c8bd | ||
|
|
2bfa0e0239 | ||
|
|
24758e8b90 | ||
|
|
432a875f0f | ||
|
|
7f4ca7b67c | ||
|
|
08ffeaae95 |
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@ -40,7 +40,7 @@ jobs:
|
||||
- name: Install QEMU static binaries
|
||||
uses: docker/setup-qemu-action@v4
|
||||
- name: Install Task
|
||||
uses: arduino/setup-task@v2
|
||||
uses: arduino/setup-task@v3.0.0
|
||||
- name: Install Dagger
|
||||
env:
|
||||
# renovate: datasource=github-tags depName=dagger/dagger versioning=semver
|
||||
|
||||
2
.github/workflows/publish-docs.yml
vendored
2
.github/workflows/publish-docs.yml
vendored
@ -28,7 +28,7 @@ jobs:
|
||||
uses: actions/checkout@v7.0.0
|
||||
|
||||
- name: Setup Node
|
||||
uses: actions/setup-node@v6
|
||||
uses: actions/setup-node@v7
|
||||
with:
|
||||
# Use the latest LTS version of Node.js already installed on the runner.
|
||||
node-version: latest
|
||||
|
||||
4
.github/workflows/release-please.yml
vendored
4
.github/workflows/release-please.yml
vendored
@ -21,13 +21,13 @@ jobs:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v7.0.0
|
||||
- name: Install node
|
||||
uses: actions/setup-node@v6
|
||||
uses: actions/setup-node@v7
|
||||
with:
|
||||
node-version: 24
|
||||
- name: Install QEMU static binaries
|
||||
uses: docker/setup-qemu-action@v4
|
||||
- name: Install Task
|
||||
uses: arduino/setup-task@v2
|
||||
uses: arduino/setup-task@v3.0.0
|
||||
- name: Install Dagger
|
||||
env:
|
||||
# renovate: datasource=github-tags depName=dagger/dagger versioning=semver
|
||||
|
||||
2
.github/workflows/release-publish.yml
vendored
2
.github/workflows/release-publish.yml
vendored
@ -17,7 +17,7 @@ jobs:
|
||||
- name: Install QEMU static binaries
|
||||
uses: docker/setup-qemu-action@v4
|
||||
- name: Install Task
|
||||
uses: arduino/setup-task@v2
|
||||
uses: arduino/setup-task@v3.0.0
|
||||
- name: Install Dagger
|
||||
env:
|
||||
# renovate: datasource=github-tags depName=dagger/dagger versioning=semver
|
||||
|
||||
2
go.mod
2
go.mod
@ -14,7 +14,7 @@ require (
|
||||
github.com/onsi/gomega v1.42.1
|
||||
github.com/spf13/cobra v1.10.2
|
||||
github.com/spf13/viper v1.21.0
|
||||
google.golang.org/grpc v1.82.0
|
||||
google.golang.org/grpc v1.82.1
|
||||
gopkg.in/yaml.v3 v3.0.1
|
||||
k8s.io/api v0.36.2
|
||||
k8s.io/apiextensions-apiserver v0.36.2
|
||||
|
||||
4
go.sum
4
go.sum
@ -293,8 +293,8 @@ google.golang.org/genproto/googleapis/api v0.0.0-20260414002931-afd174a4e478 h1:
|
||||
google.golang.org/genproto/googleapis/api v0.0.0-20260414002931-afd174a4e478/go.mod h1:C6ADNqOxbgdUUeRTU+LCHDPB9ttAMCTff6auwCVa4uc=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20260610212136-7ab31c22f7ad h1:45WmJvIV6C2+O/jjLkPUH+F3aOj/1miDoU2DD0+NWbg=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20260610212136-7ab31c22f7ad/go.mod h1:4Hqkh8ycfw05ld/3BWL7rJOSfebL2Q+DVDeRgYgxUU8=
|
||||
google.golang.org/grpc v1.82.0 h1:vguDnZUPjE26w09A63VoxZPnvPjB5Riyc0mkXPFmAIU=
|
||||
google.golang.org/grpc v1.82.0/go.mod h1:yzTZ1TB1Z3SG+LIYaI+WiE8D5+PZ3ArnrSp8zF3+/ZA=
|
||||
google.golang.org/grpc v1.82.1 h1:NnAxzGRA0677vCa4BUkOAnO5+FfQqVl9iUXeD0IqcGE=
|
||||
google.golang.org/grpc v1.82.1/go.mod h1:yzTZ1TB1Z3SG+LIYaI+WiE8D5+PZ3ArnrSp8zF3+/ZA=
|
||||
google.golang.org/protobuf v1.36.12-0.20260120151049-f2248ac996af h1:+5/Sw3GsDNlEmu7TfklWKPdQ0Ykja5VEmq2i817+jbI=
|
||||
google.golang.org/protobuf v1.36.12-0.20260120151049-f2248ac996af/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
|
||||
@ -72,8 +72,8 @@ func newAzuriteDeployment(namespace, name string) *appsv1.Deployment {
|
||||
{
|
||||
Name: name,
|
||||
// renovate: datasource=docker depName=mcr.microsoft.com/azure-storage/azurite versioning=docker
|
||||
// Version: 3.35.0
|
||||
Image: "mcr.microsoft.com/azure-storage/azurite@sha256:647c63a91102a9d8e8000aab803436e1fc85fbb285e7ce830a82ee5d6661cf37",
|
||||
// Version: 3.36.0
|
||||
Image: "mcr.microsoft.com/azure-storage/azurite@sha256:37493d0f2e764467421ffe16eb3caa39277e5fa7f6adea18eb5bbfb3c5247f98",
|
||||
Args: []string{
|
||||
"azurite-blob",
|
||||
"--blobHost",
|
||||
|
||||
@ -121,8 +121,8 @@ func newS3ClientDeployment(namespace string) *appsv1.Deployment {
|
||||
{
|
||||
Name: s3ClientName,
|
||||
// renovate: datasource=docker depName=amazon/aws-cli versioning=docker
|
||||
// Version: 2.35.11
|
||||
Image: "docker.io/amazon/aws-cli@sha256:749bfaf91d690b9a1768083822d620f96c19defdf9ca2dc227eb3695281fda5b",
|
||||
// Version: 2.35.24
|
||||
Image: "docker.io/amazon/aws-cli@sha256:f7e6c7fb03510fd1f4e27469458ca372a37c823a8c32860e0dd2f04a41787794",
|
||||
Command: []string{"sleep", "infinity"},
|
||||
Env: []corev1.EnvVar{
|
||||
{
|
||||
|
||||
@ -57,7 +57,7 @@ Both checks are required before proceeding with the installation.
|
||||
import { InstallationSnippet } from '@site/src/components/Installation';
|
||||
|
||||
Install the plugin using `kubectl` by applying the manifest for the latest
|
||||
release:
|
||||
release or using the Helm chart:
|
||||
|
||||
<InstallationSnippet />
|
||||
|
||||
|
||||
@ -485,14 +485,10 @@ If problems persist:
|
||||
|
||||
### Plugin Limitations
|
||||
|
||||
1. **Installation method**: Currently only supports manifest and Kustomize
|
||||
installation ([#351](https://github.com/cloudnative-pg/plugin-barman-cloud/issues/351) -
|
||||
Helm chart requested)
|
||||
|
||||
2. **Sidecar resource sharing**: The plugin sidecar container shares pod
|
||||
1. **Sidecar resource sharing**: The plugin sidecar container shares pod
|
||||
resources with PostgreSQL
|
||||
|
||||
3. **Plugin restart behavior**: Restarting the sidecar container requires
|
||||
2. **Plugin restart behavior**: Restarting the sidecar container requires
|
||||
restarting the entire PostgreSQL pod
|
||||
|
||||
## Recap of General Debugging Steps
|
||||
@ -588,4 +584,3 @@ kubectl get secret -n <namespace> <secret-name> -o jsonpath='{.data}' | jq 'keys
|
||||
* **"NoSuchBucket"** — Verify the bucket exists and the endpoint URL is correct.
|
||||
* **"Connection timeout"** — Check network connectivity and firewall rules.
|
||||
* **"SSL certificate problem"** — For self-signed certificates, verify the CA bundle configuration.
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@
|
||||
"@docusaurus/module-type-aliases": "3.10.2",
|
||||
"@docusaurus/tsconfig": "3.10.2",
|
||||
"@docusaurus/types": "3.10.2",
|
||||
"typescript": "~6.0.0"
|
||||
"typescript": "~7.0.0"
|
||||
},
|
||||
"browserslist": {
|
||||
"production": [
|
||||
|
||||
@ -1,16 +1,31 @@
|
||||
import {ReactElement} from 'react';
|
||||
import CodeBlock from '@theme/CodeBlock';
|
||||
import {useCurrentVersion} from '@site/src/hooks/versions';
|
||||
import {MultiLangCodeBlock} from '@site/src/components/MultiLangCodeBlock';
|
||||
|
||||
// InstallationSnippet is the kubectl incantation to install the lastest
|
||||
// available version of the Barman Cloud Plugin.
|
||||
export function InstallationSnippet(): ReactElement<null> {
|
||||
const latest = useCurrentVersion('latestReleased');
|
||||
return (
|
||||
<CodeBlock language="sh">
|
||||
{`kubectl apply -f \\
|
||||
https://github.com/cloudnative-pg/plugin-barman-cloud/releases/download/v${latest}/manifest.yaml`}
|
||||
</CodeBlock>
|
||||
);
|
||||
}
|
||||
|
||||
const snippets = [
|
||||
{
|
||||
label: 'kubectl',
|
||||
language: 'sh',
|
||||
code: `kubectl apply -f \\
|
||||
https://github.com/cloudnative-pg/plugin-barman-cloud/releases/download/v${latest}/manifest.yaml`,
|
||||
},
|
||||
{
|
||||
label: 'Helm',
|
||||
language: 'sh',
|
||||
code: `helm repo add cnpg https://cloudnative-pg.github.io/charts
|
||||
helm repo update
|
||||
helm upgrade \\
|
||||
--install \\
|
||||
--namespace cnpg-system \\
|
||||
plugin-barman-cloud cnpg/plugin-barman-cloud`,
|
||||
},
|
||||
];
|
||||
|
||||
return <MultiLangCodeBlock snippets={snippets} />;
|
||||
}
|
||||
|
||||
79
web/src/components/MultiLangCodeBlock/index.tsx
Normal file
79
web/src/components/MultiLangCodeBlock/index.tsx
Normal file
@ -0,0 +1,79 @@
|
||||
import React, {ReactElement, useState} from 'react';
|
||||
import CodeBlock from '@theme/CodeBlock';
|
||||
|
||||
export type Snippet = {
|
||||
label: string; // visible tab label (e.g. "Shell", "Helm", "Go")
|
||||
language: string; // language prop for CodeBlock (e.g. "sh", "yaml", "go")
|
||||
code: string; // the snippet to display
|
||||
};
|
||||
|
||||
type Props = {
|
||||
snippets: Snippet[];
|
||||
defaultIndex?: number;
|
||||
className?: string;
|
||||
};
|
||||
|
||||
export function MultiLangCodeBlock({snippets, defaultIndex = 0, className}: Props): ReactElement | null {
|
||||
const safeDefault = Math.max(0, Math.min(defaultIndex, snippets.length - 1));
|
||||
const [active, setActive] = useState<number>(snippets.length > 0 ? safeDefault : -1);
|
||||
|
||||
if (snippets.length === 0) return null;
|
||||
|
||||
const tabStyle: React.CSSProperties = {
|
||||
padding: '0.3rem 0.5rem',
|
||||
cursor: 'pointer',
|
||||
border: '0',
|
||||
borderRadius: 'var(--ifm-code-border-radius)',
|
||||
margin: '0 0 0 0',
|
||||
fontSize: '0.8125rem',
|
||||
color: 'inherit',
|
||||
};
|
||||
|
||||
const activeTabStyle: React.CSSProperties = {
|
||||
...tabStyle,
|
||||
fontWeight: 700,
|
||||
};
|
||||
|
||||
const tabsContainerStyle: React.CSSProperties = {
|
||||
display: 'flex',
|
||||
alignItems: 'flex-end',
|
||||
justifyContent: 'flex-end',
|
||||
gap: '0.25rem',
|
||||
margin: '0 0 -0.5rem',
|
||||
padding: '0.5rem 0.5rem 1rem',
|
||||
flexWrap: 'wrap',
|
||||
};
|
||||
|
||||
const wrapperStyle: React.CSSProperties = {
|
||||
overflow: 'hidden',
|
||||
padding: '0',
|
||||
};
|
||||
|
||||
return (
|
||||
<div className={className} style={wrapperStyle}>
|
||||
<div role="tablist" aria-label="Code snippets" style={tabsContainerStyle}>
|
||||
{snippets.map((ex, idx) => (
|
||||
<button
|
||||
key={ex.label + idx}
|
||||
role="tab"
|
||||
aria-selected={active === idx}
|
||||
aria-controls={`code-panel-${idx}`}
|
||||
id={`code-tab-${idx}`}
|
||||
onClick={() => setActive(idx)}
|
||||
style={active === idx ? activeTabStyle : tabStyle}
|
||||
>
|
||||
{ex.label}
|
||||
</button>
|
||||
))}
|
||||
</div>
|
||||
|
||||
<div role="tabpanel" id={`code-panel-${active}`} aria-labelledby={`code-tab-${active}`}>
|
||||
<CodeBlock language={snippets[active].language}>
|
||||
{snippets[active].code}
|
||||
</CodeBlock>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default MultiLangCodeBlock;
|
||||
@ -57,7 +57,7 @@ Both checks are required before proceeding with the installation.
|
||||
import { InstallationSnippet } from '@site/src/components/Installation';
|
||||
|
||||
Install the plugin using `kubectl` by applying the manifest for the latest
|
||||
release:
|
||||
release or using the Helm chart:
|
||||
|
||||
<InstallationSnippet />
|
||||
|
||||
|
||||
@ -485,14 +485,10 @@ If problems persist:
|
||||
|
||||
### Plugin Limitations
|
||||
|
||||
1. **Installation method**: Currently only supports manifest and Kustomize
|
||||
installation ([#351](https://github.com/cloudnative-pg/plugin-barman-cloud/issues/351) -
|
||||
Helm chart requested)
|
||||
|
||||
2. **Sidecar resource sharing**: The plugin sidecar container shares pod
|
||||
1. **Sidecar resource sharing**: The plugin sidecar container shares pod
|
||||
resources with PostgreSQL
|
||||
|
||||
3. **Plugin restart behavior**: Restarting the sidecar container requires
|
||||
2. **Plugin restart behavior**: Restarting the sidecar container requires
|
||||
restarting the entire PostgreSQL pod
|
||||
|
||||
## Recap of General Debugging Steps
|
||||
@ -588,4 +584,3 @@ kubectl get secret -n <namespace> <secret-name> -o jsonpath='{.data}' | jq 'keys
|
||||
* **"NoSuchBucket"** — Verify the bucket exists and the endpoint URL is correct.
|
||||
* **"Connection timeout"** — Check network connectivity and firewall rules.
|
||||
* **"SSL certificate problem"** — For self-signed certificates, verify the CA bundle configuration.
|
||||
|
||||
|
||||
1112
web/yarn.lock
1112
web/yarn.lock
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user