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
remove site url env var from frontend
Maidul Islam119600b64f48
diff --git a/frontend/src/components/utilities/config/index.ts b/frontend/src/components/utilities/config/index.tsindex 5a55658e43..7570785ba6 100644--- a/frontend/src/components/utilities/config/index.ts+++ b/frontend/src/components/utilities/config/index.ts@@ -4,13 +4,11 @@ const POSTHOG_HOST =process.env.NEXT_PUBLIC_POSTHOG_HOST! || "https://app.posthog.com";const STRIPE_PRODUCT_PRO = process.env.NEXT_PUBLIC_STRIPE_PRODUCT_PRO!;const STRIPE_PRODUCT_STARTER = process.env.NEXT_PUBLIC_STRIPE_PRODUCT_STARTER!;-const SITE_URL = "https://app.infisical.com";export {ENV,POSTHOG_API_KEY,POSTHOG_HOST,- SITE_URL,STRIPE_PRODUCT_PRO,STRIPE_PRODUCT_STARTER};\ No newline at end of filediff --git a/frontend/src/components/utilities/generateBackupPDF.ts b/frontend/src/components/utilities/generateBackupPDF.tsindex 3e2246db6a..41fb49f136 100644--- a/frontend/src/components/utilities/generateBackupPDF.ts+++ b/frontend/src/components/utilities/generateBackupPDF.ts@@ -1,7 +1,5 @@import { jsPDF } from 'jspdf';-import { SITE_URL } from './config';-interface PDFProps {personalName: string;personalEmail: string;@@ -19,7 +17,7 @@ const yyyy = today.getFullYear();const todayFormatted = `${mm}/${dd}/${yyyy}`;-function createPdfHeader(doc: jsPDF, personalName : string) {+function createPdfHeader(doc: jsPDF, personalName: string) {doc.setFillColor(255, 255, 255);doc.rect(0, 0, 600, 900, 'F');doc.setTextColor(23, 23, 23);@@ -30,6 +28,10 @@ function createPdfHeader(doc: jsPDF, personalName : string) {}function createPdfContent(doc: jsPDF, personalEmail: string, generatedKey: string) {+ const { protocol, hostname, port } = window.location;+ const portSuffix = port && port !== '80' ? `:${port}` : '';+ const siteURL = `${protocol}//${hostname}${portSuffix}`;+doc.setFontSize(14);doc.text('In case you get locked out of you Infisical account, you`ll need these account details',@@ -73,7 +75,7 @@ function createPdfContent(doc: jsPDF, personalEmail: string, generatedKey: strindoc.roundedRect(170, 488, 375, 35, 5, 5, 'F');doc.setTextColor(23, 23, 23);doc.setFontSize(14);- doc.text(`${SITE_URL}/login`, 180, 420);+ doc.text(`${siteURL}/login`, 180, 420);doc.text(personalEmail, 180, 465);doc.text(generatedKey, 180, 510);doc.text('Need help? Contact us at [email protected]', 32, 575);