commit 9b4c7cfeda956c3d2ab639b390bc6e418b3a11bd Author: henry yo Date: Mon Mar 9 00:49:08 2026 +0800 first push add linebot & search invoices diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..593098d --- /dev/null +++ b/.gitignore @@ -0,0 +1,16 @@ +# 環境變數(絕對不能上傳) +.env + +# 虛擬環境 +.venv/ +venv/ + +# Python 快取 +__pycache__/ +*.pyc +*.pyo + +# Docker +# docker-compose.yml ← 改好後可以上傳,不用擋 + +# OS 檔案 diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..9293900 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,27 @@ +version: '3.8' +services: + app: + build: ./app + ports: + - "8000:8000" + env_file: + - .env + depends_on: + - db + volumes: + - ./app:/app + - /app/.venv + + db: + image: postgres:15 + environment: + POSTGRES_USER: ${POSTGRES_USER} + POSTGRES_PASSWORD: ${POSTGRES_PASSWORD} + POSTGRES_DB: ${POSTGRES_DB} + ports: + - "5432:5432" + volumes: + - pgdata:/var/lib/postgresql/data + +volumes: + pgdata: \ No newline at end of file