openrag/assets/js/52896773.2acb1fa8.js
2025-12-16 14:05:59 +00:00

1 line
No EOL
16 KiB
JavaScript

"use strict";(globalThis.webpackChunkopenrag_docs=globalThis.webpackChunkopenrag_docs||[]).push([[6152],{937:(e,n,s)=>{s.d(n,{Ay:()=>c,RM:()=>t});var o=s(4848),r=s(8453);const t=[];function i(e){const n={admonition:"admonition",code:"code",em:"em",li:"li",p:"p",ul:"ul",...(0,r.R)(),...e.components};return(0,o.jsxs)(n.admonition,{type:"warning",children:[(0,o.jsx)(n.p,{children:"This is a destructive action that does the following:"}),(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:["Destroys all OpenRAG containers, volumes, and local images with ",(0,o.jsx)(n.code,{children:"docker compose down --volumes --remove-orphans --rmi local"}),"."]}),"\n",(0,o.jsxs)(n.li,{children:["Prunes any additional container objects with ",(0,o.jsx)(n.code,{children:"docker system prune -f"}),"."]}),"\n",(0,o.jsxs)(n.li,{children:["Deletes the contents of OpenRAG's ",(0,o.jsx)(n.code,{children:"config"})," and ",(0,o.jsx)(n.code,{children:"./opensearch-data"})," directories."]}),"\n",(0,o.jsxs)(n.li,{children:["Deletes the ",(0,o.jsx)(n.code,{children:"conversations.json"})," file."]}),"\n"]}),(0,o.jsxs)(n.p,{children:[(0,o.jsx)("p",{}),"Destroyed containers and deleted data are lost and cannot be recovered after running this operation."]}),(0,o.jsxs)(n.p,{children:["This operation ",(0,o.jsx)(n.em,{children:"doesn't"})," remove the ",(0,o.jsx)(n.code,{children:".env"})," file or the contents of the ",(0,o.jsx)(n.code,{children:"./openrag-documents"})," directory."]})]})}function c(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,o.jsx)(n,{...e,children:(0,o.jsx)(i,{...e})}):i(e)}},1381:(e,n,s)=>{s.d(n,{Ay:()=>c,RM:()=>t});var o=s(4848),r=s(8453);const t=[];function i(e){const n={code:"code",pre:"pre",...(0,r.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Docker"',children:"docker compose up -d\n"})}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Podman"',children:"podman compose up -d\n"})})]})}function c(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,o.jsx)(n,{...e,children:(0,o.jsx)(i,{...e})}):i(e)}},2046:(e,n,s)=>{s.d(n,{Ay:()=>c,RM:()=>t});var o=s(4848),r=s(8453);const t=[];function i(e){const n={code:"code",li:"li",ol:"ol",p:"p",pre:"pre",...(0,r.R)(),...e.components};return(0,o.jsxs)(n.ol,{start:"2",children:["\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsx)(n.p,{children:"Remove all containers, including stopped containers:"}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Docker"',children:"docker rm --force $(docker ps -aq)\n"})}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Podman"',children:"podman rm --all --force\n"})}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsx)(n.p,{children:"Remove all images:"}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Docker"',children:"docker rmi --force $(docker images -q)\n"})}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Podman"',children:"podman rmi --all --force\n"})}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsx)(n.p,{children:"Remove all volumes:"}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Docker"',children:"docker volume prune --force\n"})}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Podman"',children:"podman volume prune --force\n"})}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsx)(n.p,{children:"Remove all networks except the default network:"}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Docker"',children:"docker network prune --force\n"})}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Podman"',children:"podman network prune --force\n"})}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsx)(n.p,{children:"Clean up any leftover data:"}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Docker"',children:"docker system prune --all --force --volumes\n"})}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Podman"',children:"podman system prune --all --force --volumes\n"})}),"\n"]}),"\n"]})}function c(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,o.jsx)(n,{...e,children:(0,o.jsx)(i,{...e})}):i(e)}},4577:(e,n,s)=>{s.d(n,{Ay:()=>c,RM:()=>t});var o=s(4848),r=s(8453);const t=[];function i(e){const n={code:"code",pre:"pre",...(0,r.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Docker"',children:"docker stop $(docker ps -q)\n"})}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Podman"',children:"podman stop --all\n"})})]})}function c(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,o.jsx)(n,{...e,children:(0,o.jsx)(i,{...e})}):i(e)}},8453:(e,n,s)=>{s.d(n,{R:()=>i,x:()=>c});var o=s(6540);const r={},t=o.createContext(r);function i(e){const n=o.useContext(t);return o.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:i(e.components),o.createElement(t.Provider,{value:n},e.children)}},8500:(e,n,s)=>{s.r(n),s.d(n,{assets:()=>m,contentTitle:()=>p,default:()=>u,frontMatter:()=>h,metadata:()=>o,toc:()=>x});const o=JSON.parse('{"id":"get-started/reinstall","title":"Reinstall OpenRAG","description":"You can reset your OpenRAG deployment to its initial state by recreating the containers and deleting accessory data, such as the .env file and ingested documents.","source":"@site/docs/get-started/reinstall.mdx","sourceDirName":"get-started","slug":"/reinstall","permalink":"/reinstall","draft":false,"unlisted":false,"editUrl":"https://github.com/openrag/openrag/tree/main/docs/docs/get-started/reinstall.mdx","tags":[],"version":"current","frontMatter":{"title":"Reinstall OpenRAG","slug":"/reinstall"},"sidebar":"tutorialSidebar","previous":{"title":"Upgrade OpenRAG","permalink":"/upgrade"},"next":{"title":"Remove OpenRAG","permalink":"/uninstall"}}');var r=s(4848),t=s(8453),i=s(1381),c=s(9809),a=s(4577),l=s(2046),d=s(937);const h={title:"Reinstall OpenRAG",slug:"/reinstall"},p=void 0,m={},x=[{value:"Export customized flows before reinstalling",id:"export-customized-flows-before-reinstalling",level:2},{value:"Reinstall TUI-managed containers",id:"reinstall-tui-managed-containers",level:2},...d.RM,{value:"Reinstall self-managed containers with <code>docker compose</code> or <code>podman compose</code>",id:"reinstall-self-managed-containers-with-docker-compose-or-podman-compose",level:2},...c.RM,...i.RM,{value:"Reinstall self-managed containers with discrete <code>docker</code> or <code>podman</code> commands",id:"reinstall-self-managed-containers-with-discrete-docker-or-podman-commands",level:2},...a.RM,...l.RM];function j(e){const n={a:"a",admonition:"admonition",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,t.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(n.p,{children:["You can reset your OpenRAG deployment to its initial state by recreating the containers and deleting accessory data, such as the ",(0,r.jsx)(n.code,{children:".env"})," file and ingested documents."]}),"\n",(0,r.jsx)(n.admonition,{type:"warning",children:(0,r.jsx)(n.p,{children:"These are destructive operations that reset your OpenRAG deployment to an initial state.\nDestroyed containers and deleted data are lost and cannot be recovered after running these operations."})}),"\n",(0,r.jsx)(n.h2,{id:"export-customized-flows-before-reinstalling",children:"Export customized flows before reinstalling"}),"\n",(0,r.jsxs)(n.p,{children:["If you modified the built-in flows or created custom flows in your OpenRAG Langflow instance, and you want to preserve those changes, ",(0,r.jsx)(n.a,{href:"https://docs.langflow.org/concepts-flows-import",children:"export your flows"})," before reinstalling OpenRAG."]}),"\n",(0,r.jsx)(n.h2,{id:"reinstall-tui-managed-containers",children:"Reinstall TUI-managed containers"}),"\n",(0,r.jsxs)(n.ol,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:["In the TUI's ",(0,r.jsx)(n.strong,{children:"Status"})," menu (",(0,r.jsx)("kbd",{children:"3"}),"), click ",(0,r.jsx)(n.strong,{children:"Factory Reset"})," to destroy your OpenRAG containers and some related data."]}),"\n",(0,r.jsx)(d.Ay,{}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:["Exit the TUI with ",(0,r.jsx)("kbd",{children:"q"}),"."]}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:["Optional: Remove data that wasn't deleted by the ",(0,r.jsx)(n.strong,{children:"Factory Reset"})," operation.\nFor a completely fresh installation, delete all of this data."]}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:[(0,r.jsxs)(n.strong,{children:["OpenRAG's ",(0,r.jsx)(n.code,{children:".env"})," file"]}),": Contains your OpenRAG configuration, including OpenRAG passwords, API keys, OAuth settings, and other ",(0,r.jsx)(n.a,{href:"/reference/configuration",children:"environment variables"}),". If you delete this file, OpenRAG automatically generates a new one after you repeat the setup and onboarding process. Alternatively, you can add a prepopulated ",(0,r.jsx)(n.code,{children:".env"})," file to your OpenRAG installation directory before restarting OpenRAG."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsxs)(n.strong,{children:["The contents of the ",(0,r.jsx)(n.code,{children:"./openrag-documents"})," directory"]}),": Contains documents that you uploaded to OpenRAG. Delete these files to prevent documents from being reingested to your knowledge base after restarting OpenRAG. However, you might want to preserve OpenRAG's ",(0,r.jsx)(n.a,{href:"https://github.com/langflow-ai/openrag/tree/main/openrag-documents",children:"default documents"}),"."]}),"\n"]}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:["Restart the TUI with ",(0,r.jsx)(n.code,{children:"uv run openrag"})," or ",(0,r.jsx)(n.code,{children:"uvx openrag"}),"."]}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:["Repeat the ",(0,r.jsx)(n.a,{href:"/install#setup",children:"setup process"})," to configure OpenRAG and restart all services.\nThen, launch the OpenRAG app and repeat the ",(0,r.jsx)(n.a,{href:"/install#application-onboarding",children:"application onboarding process"}),"."]}),"\n",(0,r.jsxs)(n.p,{children:["If OpenRAG detects a ",(0,r.jsx)(n.code,{children:".env"})," file during setup and onboarding, it automatically populates any OpenRAG passwords, OAuth credentials, and onboarding configuration set in that file."]}),"\n"]}),"\n"]}),"\n",(0,r.jsxs)(n.h2,{id:"reinstall-self-managed-containers-with-docker-compose-or-podman-compose",children:["Reinstall self-managed containers with ",(0,r.jsx)(n.code,{children:"docker compose"})," or ",(0,r.jsx)(n.code,{children:"podman compose"})]}),"\n",(0,r.jsxs)(n.p,{children:["Use these steps to reinstall OpenRAG containers with streamlined ",(0,r.jsx)(n.code,{children:"docker compose"})," or ",(0,r.jsx)(n.code,{children:"podman compose"})," commands:"]}),"\n",(0,r.jsxs)(n.ol,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Destroy the containers, volumes, and local images, and then remove (prune) any additional container objects:"}),"\n",(0,r.jsx)(c.Ay,{}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Optional: Remove data that wasn't deleted by the previous commands:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["OpenRAG's ",(0,r.jsx)(n.code,{children:".env"})," file"]}),"\n",(0,r.jsxs)(n.li,{children:["The contents of OpenRAG's ",(0,r.jsx)(n.code,{children:"config"})," directory"]}),"\n",(0,r.jsxs)(n.li,{children:["The contents of the ",(0,r.jsx)(n.code,{children:"./openrag-documents"})," directory"]}),"\n",(0,r.jsxs)(n.li,{children:["The contents of the ",(0,r.jsx)(n.code,{children:"./opensearch-data"})," directory"]}),"\n",(0,r.jsxs)(n.li,{children:["The ",(0,r.jsx)(n.code,{children:"conversations.json"})," file"]}),"\n"]}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:["If you deleted the ",(0,r.jsx)(n.code,{children:".env"})," file, prepare a new ",(0,r.jsx)(n.code,{children:".env"})," before redeploying the containers.\nFor more information, see ",(0,r.jsx)(n.a,{href:"/docker",children:"Deploy OpenRAG with self-managed services"}),"."]}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Redeploy OpenRAG:"}),"\n",(0,r.jsx)(i.Ay,{}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:["Launch the OpenRAG app, and then repeat the ",(0,r.jsx)(n.a,{href:"/docker#application-onboarding",children:"application onboarding process"}),"."]}),"\n"]}),"\n"]}),"\n",(0,r.jsxs)(n.h2,{id:"reinstall-self-managed-containers-with-discrete-docker-or-podman-commands",children:["Reinstall self-managed containers with discrete ",(0,r.jsx)(n.code,{children:"docker"})," or ",(0,r.jsx)(n.code,{children:"podman"})," commands"]}),"\n",(0,r.jsxs)(n.p,{children:["Use these commands to remove and clean up OpenRAG containers with discrete ",(0,r.jsx)(n.code,{children:"docker"})," or ",(0,r.jsx)(n.code,{children:"podman"})," commands."]}),"\n",(0,r.jsx)(n.p,{children:"If you want to reinstall one container, specify the container name in the commands instead of running the commands on all containers."}),"\n",(0,r.jsxs)(n.ol,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Stop all running containers:"}),"\n",(0,r.jsx)(a.Ay,{}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(l.Ay,{}),"\n",(0,r.jsxs)(n.ol,{start:"7",children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Optional: Remove data that wasn't deleted by the previous commands:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["OpenRAG's ",(0,r.jsx)(n.code,{children:".env"})," file"]}),"\n",(0,r.jsxs)(n.li,{children:["The contents of OpenRAG's ",(0,r.jsx)(n.code,{children:"config"})," directory"]}),"\n",(0,r.jsxs)(n.li,{children:["The contents of the ",(0,r.jsx)(n.code,{children:"./openrag-documents"})," directory"]}),"\n",(0,r.jsxs)(n.li,{children:["The contents of the ",(0,r.jsx)(n.code,{children:"./opensearch-data"})," directory"]}),"\n",(0,r.jsxs)(n.li,{children:["The ",(0,r.jsx)(n.code,{children:"conversations.json"})," file"]}),"\n"]}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:["If you removed all OpenRAG containers, ",(0,r.jsx)(n.a,{href:"/docker",children:"redeploy OpenRAG"}),".\nIf you removed only one container, redeploy that container with the appropriate ",(0,r.jsx)(n.code,{children:"docker run"})," or ",(0,r.jsx)(n.code,{children:"podman run"})," command."]}),"\n"]}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,t.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(j,{...e})}):j(e)}},9809:(e,n,s)=>{s.d(n,{Ay:()=>c,RM:()=>t});var o=s(4848),r=s(8453);const t=[];function i(e){const n={code:"code",pre:"pre",...(0,r.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Docker"',children:"docker compose down --volumes --remove-orphans --rmi local\ndocker system prune -f\n"})}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{className:"language-bash",metastring:'title="Podman"',children:"podman compose down --volumes --remove-orphans --rmi local\npodman system prune -f\n"})})]})}function c(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,o.jsx)(n,{...e,children:(0,o.jsx)(i,{...e})}):i(e)}}}]);