feat: add S3_PROVIDER to daemonset and secret

- Introduce S3_PROVIDER environment variable in daemonset.yaml
- Update secret.yaml to include provider information

This change allows the application to specify the S3 provider type, improving
flexibility in storage configuration. The new variable is sourced from the
existing s3-credentials secret, ensuring secure access to the provider
information.
This commit is contained in:
songtianlun 2025-04-26 11:07:57 +08:00
parent dda3e92a63
commit 31c0176813
2 changed files with 14 additions and 0 deletions

View File

@ -75,6 +75,11 @@ spec:
secretKeyRef:
name: s3-credentials
key: bucket
- name: S3_PROVIDER
valueFrom:
secretKeyRef:
name: s3-credentials
key: provider
- name: S3_SUBPATH
valueFrom:
configMapKeyRef:
@ -195,6 +200,12 @@ spec:
secretKeyRef:
name: s3-credentials
key: agz-bucket
- name: S3_PROVIDER
valueFrom:
secretKeyRef:
name: s3-credentials
key: agz-provider
- name: S3_SUBPATH
valueFrom:
configMapKeyRef:
@ -239,3 +250,4 @@ spec:
secret:
secretName: feishu-webhook

View File

@ -6,10 +6,12 @@ metadata:
type: Opaque
data:
# 这些值需要使用base64编码替换
provider: TWluaW8= # Minio
endpoint: aHR0cHM6Ly9hcGkubWluaW8uc2t5Ynl0ZS5tZQ== # https://api.minio.skybyte.me
access-key: RVZuWFViR2xld2t0dFF0em9XUWs= # EVnXUbGlewkttQtzoWQk
secret-key: THNxVFRmc0VEVzBFY3Buc09aOUxyTnhwc21zajdIMGxlR2R0WHBwRg== # LsqTTfsEDW0EcpnsOZ9LrNxpsmsj7H0leGdtXppF
bucket: YmFja3Vwcw== # backups
agz-provider: QWxpYmFiYQ== # Alibaba
agz-endpoint: b3NzLWNuLWd1YW5nemhvdS1pbnRlcm5hbC5hbGl5dW5jcy5jb20= # https://oss-cn-guangzhou-internal.aliyuncs.com
agz-access-key: TFRBSTV0QnU3VmppOEh6Z3NyZFN1dlhx # LTAI5tBu7Vji8HzgsrdSuvXq
agz-secret-key: S0REcGZpUWlRSzY5em9taTVYTEpuNUlUTDZtc3l0 # KDDpfiQiQK69zomi5XLJn5ITL6msyt