Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

Allow docs to run fully offline

x032205a6edb67f589c
diff --git a/docs/Dockerfile b/docs/Dockerfile
index 34730d01e5..079972544d 100644
--- a/docs/Dockerfile
+++ b/docs/Dockerfile
@@ -1,6 +1,32 @@
+FROM node:20-alpine AS builder
+
+WORKDIR /app
+
+RUN npm install -g [email protected]
+
+COPY . .
+
+# Install a local version of our OpenAPI spec
+RUN apk add --no-cache wget jq && \
+ wget -O spec.json https://app.infisical.com/api/docs/json && \
+ jq '.api.openapi = "./spec.json"' docs.json > temp.json && \
+ mv temp.json docs.json
+
+# Run mint dev briefly to download the web client
+RUN timeout 30 mint dev || true
+
FROM node:20-alpine
+
WORKDIR /app
-RUN npm install -g mint
+
+RUN npm install -g [email protected]
+
COPY . .
+
+COPY --from=builder /root/.mintlify /root/.mintlify
+COPY --from=builder /app/docs.json /app/docs.json
+COPY --from=builder /app/spec.json /app/spec.json
+
EXPOSE 3000
+
CMD ["mint", "dev"]
diff --git a/docs/docs.json b/docs/docs.json
index f8e7aee4ed..8e6972429a 100644
--- a/docs/docs.json
+++ b/docs/docs.json
@@ -78,7 +78,10 @@
},
{
"group": "Infisical SSH",
- "pages": ["documentation/platform/ssh/overview", "documentation/platform/ssh/host-groups"]
+ "pages": [
+ "documentation/platform/ssh/overview",
+ "documentation/platform/ssh/host-groups"
+ ]
},
{
"group": "Key Management (KMS)",
@@ -375,7 +378,10 @@
},
{
"group": "Architecture",
- "pages": ["internals/architecture/components", "internals/architecture/cloud"]
+ "pages": [
+ "internals/architecture/components",
+ "internals/architecture/cloud"
+ ]
},
"internals/security",
"internals/service-tokens"
@@ -546,7 +552,10 @@
"integrations/cloud/gcp-secret-manager",
{
"group": "Cloudflare",
- "pages": ["integrations/cloud/cloudflare-pages", "integrations/cloud/cloudflare-workers"]
+ "pages": [
+ "integrations/cloud/cloudflare-pages",
+ "integrations/cloud/cloudflare-workers"
+ ]
},
"integrations/cloud/terraform-cloud",
"integrations/cloud/databricks",
@@ -658,7 +667,11 @@
"cli/commands/reset",
{
"group": "infisical scan",
- "pages": ["cli/commands/scan", "cli/commands/scan-git-changes", "cli/commands/scan-install"]
+ "pages": [
+ "cli/commands/scan",
+ "cli/commands/scan-git-changes",
+ "cli/commands/scan-install"
+ ]
}
]
},
@@ -982,7 +995,9 @@
"pages": [
{
"group": "Kubernetes",
- "pages": ["api-reference/endpoints/dynamic-secrets/kubernetes/create-lease"]
+ "pages": [
+ "api-reference/endpoints/dynamic-secrets/kubernetes/create-lease"
+ ]
},
"api-reference/endpoints/dynamic-secrets/create",
"api-reference/endpoints/dynamic-secrets/update",