diff --git a/.github/workflows/container.yml b/.github/workflows/container.yml index f95061eeb49..801ecf45f7b 100644 --- a/.github/workflows/container.yml +++ b/.github/workflows/container.yml @@ -32,6 +32,7 @@ jobs: run: | cp .env.example .env docker-compose build + docker build -f Dockerfile.multi --target api-build -t librechat-api . # Get Tag Name - name: Get Tag Name @@ -45,3 +46,7 @@ jobs: docker push ghcr.io/${{ github.repository_owner }}/librechat:${{ env.TAG_NAME }} docker tag librechat:latest ghcr.io/${{ github.repository_owner }}/librechat:latest docker push ghcr.io/${{ github.repository_owner }}/librechat:latest + docker tag librechat-api:latest ghcr.io/${{ github.repository_owner }}/librechat-api:${{ env.TAG_NAME }} + docker push ghcr.io/${{ github.repository_owner }}/librechat-api:${{ env.TAG_NAME }} + docker tag librechat-api:latest ghcr.io/${{ github.repository_owner }}/librechat-api:latest + docker push ghcr.io/${{ github.repository_owner }}/librechat-api:latest diff --git a/api/package.json b/api/package.json index e52ba85260a..6f0b6f8a001 100644 --- a/api/package.json +++ b/api/package.json @@ -1,6 +1,6 @@ { "name": "@librechat/backend", - "version": "0.5.7", + "version": "0.5.8", "description": "", "scripts": { "start": "echo 'please run this from the root directory'", diff --git a/client/package.json b/client/package.json index b41876c854a..919d274f5fd 100644 --- a/client/package.json +++ b/client/package.json @@ -1,6 +1,6 @@ { "name": "@librechat/frontend", - "version": "0.5.7", + "version": "0.5.8", "description": "", "scripts": { "data-provider": "cd .. && npm run build:data-provider", diff --git a/client/src/components/Input/Footer.tsx b/client/src/components/Input/Footer.tsx index 202500f60c9..528d1a995f8 100644 --- a/client/src/components/Input/Footer.tsx +++ b/client/src/components/Input/Footer.tsx @@ -14,7 +14,7 @@ export default function Footer() { rel="noreferrer" className="underline" > - {config?.appTitle || 'LibreChat'} v0.5.7 + {config?.appTitle || 'LibreChat'} v0.5.8 {' - '}. {localize('com_ui_pay_per_call')} diff --git a/docs/deployment/digitalocean.md b/docs/deployment/digitalocean.md index 9a0777e4d8d..2f7e45854ec 100644 --- a/docs/deployment/digitalocean.md +++ b/docs/deployment/digitalocean.md @@ -21,24 +21,28 @@ Digital Ocean is also my preferred choice for testing deployment, as it comes wi ## Table of Contents - **[Part I: Starting from Zero](#part-i-starting-from-zero)** - - [1. DigitalOcean signup](#1-click-here-or-on-the-banner-above-to-get-started-on-digitalocean) - - [2. Access console](#2-access-your-droplet-console) - - [3. Console user setup](#3-once-you-have-logged-in-immediately-create-a-new-non-root-user) + - [1. DigitalOcean signup](#1-click-here-or-on-the-banner-above-to-get-started-on-digitalocean) + - [2. Access console](#2-access-your-droplet-console) + - [3. Console user setup](#3-once-you-have-logged-in-immediately-create-a-new-non-root-user) + - [4. Firewall Setup](#4-firewall-setup) - **[Part II: Installing Docker & Other Dependencies](#part-ii-installing-docker-and-other-dependencies)** - - [1. Update and Install Docker dependencies](#1-update-and-install-docker-dependencies) - - [2. Add Docker Repository to APT Sources](#2-add-docker-repository-to-apt-sources) - - [3. Install Docker](#3-install-docker) - - [4. Verify Docker](#4-verify-that-docker-is-running-on-ubuntu) - - [5. Install the Latest Version of Docker Compose](#5-install-the-latest-version-of-docker-compose) - - [6. Install git & npm](#6-as-part-of-this-guide-i-will-recommend-you-have-git-and-npm-installed) + - [1. Update and Install Docker dependencies](#1-update-and-install-docker-dependencies) + - [2. Add Docker Repository to APT Sources](#2-add-docker-repository-to-apt-sources) + - [3. Install Docker](#3-install-docker) + - [4. Verify Docker](#4-verify-that-docker-is-running-on-ubuntu) + - [5. Install the Latest Version of Docker Compose](#5-install-the-latest-version-of-docker-compose) + - [6. Install git & npm](#6-as-part-of-this-guide-i-will-recommend-you-have-git-and-npm-installed) - **[Part III: Setup LibreChat](#part-iii-setup-librechat)** - - [1. Clone down the repo](#1-clone-down-the-repo) - - [2. Create a global environment file](#2-create-a-global-environment-file) - - [3. Start docker and run LibreChat](#3-start-docker-and-then-run-the-installationupdate-script) - - [4. Access LibreChat](#4-once-the-app-is-running-you-can-access-it-at-httpyourserverip) + - [1. Clone down the repo](#1-clone-down-the-repo) + - [2. Create a global environment file](#2-create-a-global-environment-file) + - [3. Start docker and run LibreChat](#3-start-docker-and-then-run-the-installationupdate-script) + - [4. Access LibreChat](#4-once-the-app-is-running-you-can-access-it-at-httpyourserverip) - **[Part IV: Updating LibreChat](#part-iv-updating-librechat)** -- **[Part V: Editing the NGINX file (optional)](#part-v-editing-the-nginx-file-for-custom-domains-and-advanced-configs)** +> The last sections are all optional configurations + +- **[Part V: Editing the NGINX file](#part-v-editing-the-nginx-file-for-custom-domains-and-advanced-configs)** +- **[Part VI: Use the Latest Stable Release instead of Latest Main Branch](#part-vi-use-the-latest-stable-release-instead-of-latest-main-branch)** ## Part I: Starting from Zero: @@ -120,6 +124,18 @@ getent group sudo | cut -d: -f4 su - ``` +### **4. Firewall Setup** + +It's highly recommended you setup a simple firewall for your setup. + +Click on your droplet from the projects page again, and goto the Networking tab on the left-hand side under your ipv4: + +![image](https://github.com/danny-avila/LibreChat/assets/110412045/20a2f31b-83ec-4052-bca7-27a672c3770a) + +Create a firewall, add your droplet to it, and add these inbound rules (will work for this guide, but configure as needed) + +![image](https://github.com/danny-avila/LibreChat/assets/110412045/d9bbdd7b-3702-4d2d-899b-c6457e6d221a) + --- ### Part II: Installing Docker and Other Dependencies: @@ -287,13 +303,22 @@ cd LibreChat/ ``` ### **2. Create a global environment file.** -The default values are enough to get you started and running the app! API credentials can be provided when accessing the web app. +The default values are enough to get you started and running the app. ```bash # Copies the example file as your global env file cp .env.example .env ``` +However, it's highly recommended you use environment variables for any sensitive credentials until we remove use of localStorage for passing credentials from the frontend + +```bash +nano .env + +# then, add your credentials +OPENAI_API_KEY=sk-yourKey +``` + **That's it!** For thorough configuration, however, you should edit your .env file as needed, and do read the comments in the file and the resources below. @@ -447,8 +472,7 @@ You should be all set! > Note that any changes to the code in this environment won't be reflected because the compose file is pulling the docker images built automatically by GitHub - +Change `librechat-dev-api` to `librechat-api`: + +```yaml +image: ghcr.io/danny-avila/librechat-api:latest +``` + +Stage and commit as in Part V, and you're all set! --- diff --git a/docs/features/plugins/make_your_own.md b/docs/features/plugins/make_your_own.md index 498f5777c03..4e7f2eb016e 100644 --- a/docs/features/plugins/make_your_own.md +++ b/docs/features/plugins/make_your_own.md @@ -159,6 +159,7 @@ const StableDiffusionAPI = require('./StableDiffusion'); ``` In handleTools.js, find the beginning of the `loadTools` function and add your plugin/tool to the toolConstructors object. + ```js const loadTools = async ({ user, model, tools = [], options = {} }) => { const toolConstructors = { @@ -169,7 +170,7 @@ const loadTools = async ({ user, model, tools = [], options = {} }) => { 'stable-diffusion': StableDiffusionAPI // <----- Newly Added. Note: the key is the 'name' provided in the class. // We will now refer to this name as the `pluginKey` }; - ``` +``` If your Tool class requires more advanced initialization, you would add it to the customConstructors object. diff --git a/package-lock.json b/package-lock.json index 867ed0fbe8b..fb1ff38d47a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "LibreChat", - "version": "0.5.7", + "version": "0.5.8", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "LibreChat", - "version": "0.5.7", + "version": "0.5.8", "hasInstallScript": true, "license": "ISC", "workspaces": [ @@ -44,7 +44,7 @@ }, "api": { "name": "@librechat/backend", - "version": "0.5.7", + "version": "0.5.8", "license": "ISC", "dependencies": { "@anthropic-ai/sdk": "^0.5.4", @@ -497,7 +497,7 @@ }, "client": { "name": "@librechat/frontend", - "version": "0.5.7", + "version": "0.5.8", "license": "ISC", "dependencies": { "@fortawesome/fontawesome-svg-core": "^6.4.0", diff --git a/package.json b/package.json index e8313b10b97..9c6aa245919 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "LibreChat", - "version": "0.5.7", + "version": "0.5.8", "description": "", "workspaces": [ "api",