There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.
TypeScript appcrdteditorelectronknowledge-basemarkdownmironotesnotionnotion-alternativerustrust-langrust-languagetabletableviewwhiteboardwikiworkspace
chore(server): add stripe env
Joooye_346fcdb059253a
diff --git a/.github/actions/deploy/deploy.mjs b/.github/actions/deploy/deploy.mjsindex b38c117e39..8cb74a05f5 100644--- a/.github/actions/deploy/deploy.mjs+++ b/.github/actions/deploy/deploy.mjs@@ -25,6 +25,8 @@ const {GCLOUD_CLOUD_SQL_INTERNAL_ENDPOINT,REDIS_HOST,REDIS_PASSWORD,+ STRIPE_API_KEY,+ STRIPE_WEBHOOK_KEY,} = process.env;// eslint-disable-next-line @typescript-eslint/no-non-null-assertion@@ -96,6 +98,8 @@ const createHelmCommand = ({ isDryRun }) => {`--set-string graphql.app.oauth.google.enabled=true`,`--set-string graphql.app.oauth.google.clientId="${AFFINE_GOOGLE_CLIENT_ID}"`,`--set-string graphql.app.oauth.google.clientSecret="${AFFINE_GOOGLE_CLIENT_SECRET}"`,+ `--set-string graphql.app.payment.stripe.apiKey="${STRIPE_API_KEY}"`,+ `--set-string graphql.app.payment.stripe.webhookKey="${STRIPE_WEBHOOK_KEY}"`,`--set graphql.app.experimental.enableJwstCodec=true`,`--set sync.replicaCount=${syncReplicaCount}`,`--set-string sync.image.tag="${imageTag}"`,diff --git a/.github/helm/affine/charts/graphql/templates/deployment.yaml b/.github/helm/affine/charts/graphql/templates/deployment.yamlindex efb6799100..295a226839 100644--- a/.github/helm/affine/charts/graphql/templates/deployment.yaml+++ b/.github/helm/affine/charts/graphql/templates/deployment.yaml@@ -100,6 +100,16 @@ spec:secretKeyRef:name: "{{ .Values.app.oauth.email.secretName }}"key: password+ - name: STRIPE_API_KEY+ valueFrom:+ secretKeyRef:+ name: "{{ .Values.app.payment.stripe.secretName }}"+ key: stripeAPIKey+ - name: STRIPE_WEBHOOK_KEY+ valueFrom:+ secretKeyRef:+ name: "{{ .Values.app.payment.stripe.secretName }}"+ key: stripeWebhookKey- name: DOC_MERGE_INTERVALvalue: "{{ .Values.app.doc.mergeInterval }}"{{ if .Values.app.experimental.enableJwstCodec }}diff --git a/.github/helm/affine/charts/graphql/templates/payment.yml b/.github/helm/affine/charts/graphql/templates/payment.ymlnew file mode 100644index 0000000000..ec89e0201f--- /dev/null+++ b/.github/helm/affine/charts/graphql/templates/payment.yml@@ -0,0 +1,8 @@+apiVersion: v1+kind: Secret+metadata:+ name: "{{ .Values.app.payment.stripe.secretName }}"+type: Opaque+data:+ stripeAPIKey: "{{ .Values.app.payment.stripe.apiKey | b64enc }}"+ stripeWebhookKey: "{{ .Values.app.payment.stripe.webhookKey | b64enc }}"diff --git a/.github/helm/affine/charts/graphql/values.yaml b/.github/helm/affine/charts/graphql/values.yamlindex 41d5448434..4aacb499fd 100644--- a/.github/helm/affine/charts/graphql/values.yaml+++ b/.github/helm/affine/charts/graphql/values.yaml@@ -53,6 +53,11 @@ app:secretName: oauth-githubclientId: ''clientSecret: ''+ payment:+ stripe:+ secretName: 'stripe'+ apiKey: ''+ webhookKey: ''serviceAccount:create: truediff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.ymlindex ead24994cf..9e5a119d6b 100644--- a/.github/workflows/deploy.yml+++ b/.github/workflows/deploy.yml@@ -247,3 +247,5 @@ jobs:REDIS_HOST: ${{ secrets.REDIS_HOST }}REDIS_PASSWORD: ${{ secrets.REDIS_PASSWORD }}CLOUD_SQL_IAM_ACCOUNT: ${{ secrets.CLOUD_SQL_IAM_ACCOUNT }}+ STRIPE_API_KEY: ${{ secrets.STRIPE_API_KEY }}+ STRIPE_WEBHOOK_KEY: ${{ secrets.STRIPE_WEBHOOK_KEY }}