Skip to content

Commit

Permalink
feat: add package script in Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
huajianmao committed Aug 5, 2023
1 parent 9456a49 commit 3e24eb9
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
6 changes: 3 additions & 3 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

SERVER_HOST = "127.0.0.1"
SERVER_HOST = "0.0.0.0"
SERVER_PORT = 8000

API_PREFIX = "/api/v1"
Expand All @@ -10,5 +10,5 @@ LLMS_DISABLED = "Llama-2-13b-chat-hf, internlm/internlm-chat-7b, internlm/intern

# MODEL_HUB_PATH = "models"

UPLOAD_FOLDER = "/tmp/openai.mini/files"
IMAGE_FOLDER = "/tmp/openai.mini/images"
UPLOAD_FOLDER = "./upload/files"
IMAGE_FOLDER = "./upload/images"
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# Ignore web, models except the .gitkeep file
# Ignore web, dist, models except the .gitkeep file
dist/*
!dist/.gitkeep
models/*
!models/.gitkeep
web/*
Expand Down
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,10 @@ install:
.PHONY: run
run:
python3 -m src.api

package:
rm -rf dist/openai.mini
mkdir dist/openai.mini
mkdir dist/openai.mini/models
cp -r .env.example requirements.txt docs Makefile README.md src web dist/openai.mini/
cd dist && tar zcvf openai.mini.tar.gz openai.mini
Empty file added dist/.gitkeep
Empty file.

0 comments on commit 3e24eb9

Please sign in to comment.