Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.
TypeScript acmeagentsai-agentscertificate-managementdevsecopsenvironment-variableskubernetesopen-sourcepampkipostgresprivate-caprivileged-access-managementsecret-managementsecret-managersecretssecrets-managementsecuritysecurity-toolsvault
fix issues
Matheus Nogueira87b47c76b5f4
diff --git a/backend/src/services/app-connection/netlify/netlify-connection-public-client.ts b/backend/src/services/app-connection/netlify/netlify-connection-public-client.tsindex 04b9fe8c19..1c01f129fc 100644--- a/backend/src/services/app-connection/netlify/netlify-connection-public-client.ts+++ b/backend/src/services/app-connection/netlify/netlify-connection-public-client.ts@@ -95,29 +95,13 @@ class NetlifyPublicClient {}async getVariables(connection: TNetlifyConnectionConfig, { account_id, ...params }: NetlifyParams) {- const PAGE_SIZE = 100;- const allVariables: TNetlifyVariable[] = [];- let page = 1;-- // eslint-disable-next-line no-constant-condition, @typescript-eslint/no-unnecessary-condition- while (true) {- const res = await this.send<TNetlifyVariable[]>(connection, {- method: "GET",- url: `/accounts/${account_id}/env`,- params: {- ...params,- limit: PAGE_SIZE,- page- }- });-- allVariables.push(...res);-- if (res.length < PAGE_SIZE) break;- page += 1;- }-- return allVariables;+ // This public endpoint doesn't support validation, but it also returns all variables.+ // Tested with 900 secrets.+ return await this.send<TNetlifyVariable[]>(connection, {+ method: "GET",+ url: `/accounts/${account_id}/env`,+ params+ });}async createVariable(@@ -187,21 +171,6 @@ class NetlifyPublicClient {}}- async upsertVariable(connection: TNetlifyConnectionConfig, params: NetlifyParams, variable: TNetlifyVariable) {- const res = await this.getVariable(connection, params, variable);-- if (!res) {- return this.createVariable(connection, params, variable);- }-- if (res.is_secret) {- await this.deleteVariable(connection, params, variable);- return this.createVariable(connection, params, variable);- }-- return this.updateVariable(connection, params, variable);- }-async deleteVariable(connection: TNetlifyConnectionConfig,{ account_id, ...params }: NetlifyParams,diff --git a/docs/integrations/secret-syncs/netlify.mdx b/docs/integrations/secret-syncs/netlify.mdxindex c1c51d4529..599c58a4d8 100644--- a/docs/integrations/secret-syncs/netlify.mdx+++ b/docs/integrations/secret-syncs/netlify.mdx@@ -39,6 +39,9 @@ description: "Learn how to configure a Netlify Sync for Infisical."- **Account**: The Netlify Account to be used.- **Site**: The Netlify site where secrets should be synced.- **Context**: The Netlify deployment context where secrets should be created in.+ <Info>+ If you have multiple syncs configured to the same site and context, they may conflict with each other and delete each other's secrets during sync operations. This can also happen if one of the syncs has "All Contexts" selected, since it overlaps with every other context. When setting up multiple syncs, make sure they target different contexts to prevent this.+ </Info></Step><Step title="Configure Sync Options">Configure the **Sync Options** to specify how secrets should be synced, then click **Next**.diff --git a/frontend/src/pages/organization/AppConnections/AppConnectionsPage/components/AppConnectionForm/AppConnectionForm.tsx b/frontend/src/pages/organization/AppConnections/AppConnectionsPage/components/AppConnectionForm/AppConnectionForm.tsxindex 2173753b0b..21328cfb70 100644--- a/frontend/src/pages/organization/AppConnections/AppConnectionsPage/components/AppConnectionForm/AppConnectionForm.tsx+++ b/frontend/src/pages/organization/AppConnections/AppConnectionsPage/components/AppConnectionForm/AppConnectionForm.tsx@@ -555,6 +555,8 @@ const UpdateForm = ({ appConnection, onComplete }: UpdateFormProps) => {return <VenafiConnectionForm onSubmit={onSubmit} appConnection={appConnection} />;case AppConnection.VenafiTpp:return <VenafiTppConnectionForm onSubmit={onSubmit} appConnection={appConnection} />;+ case AppConnection.Netlify:+ return <NetlifyConnectionForm onSubmit={onSubmit} appConnection={appConnection} />default:throw new Error(`Unhandled App ${(appConnection as TAppConnection).app}`);}