Browse Source

Added Docker support

maziggy 5 months ago
parent
commit
0194a0498e
3 changed files with 16 additions and 10 deletions
  1. 1 2
      Dockerfile
  2. 12 8
      README.md
  3. 3 0
      build_docker.sh

+ 1 - 2
Dockerfile

@@ -4,8 +4,7 @@ FROM node:22-bookworm-slim AS frontend-builder
 WORKDIR /app/frontend
 WORKDIR /app/frontend
 
 
 COPY frontend/package*.json ./
 COPY frontend/package*.json ./
-RUN npm ci --ignore-scripts && \
-    npm rebuild esbuild
+RUN npm ci
 
 
 COPY frontend/ ./
 COPY frontend/ ./
 RUN npm run build
 RUN npm run build

+ 12 - 8
README.md

@@ -130,27 +130,31 @@
 ## 🚀 Quick Start
 ## 🚀 Quick Start
 
 
 ### Requirements
 ### Requirements
-- Python 3.10+ (3.11/3.12 recommended)
 - Bambu Lab printer with **LAN Mode** enabled
 - Bambu Lab printer with **LAN Mode** enabled
 - Same local network as printer
 - Same local network as printer
 
 
-### Installation
+### Docker (Recommended)
+
+```bash
+git clone https://github.com/maziggy/bambuddy.git
+cd bambuddy
+docker compose up -d
+```
+
+Open **http://localhost:8000** and add your printer!
+
+### Manual Installation
 
 
 ```bash
 ```bash
-# Clone and setup
 git clone https://github.com/maziggy/bambuddy.git
 git clone https://github.com/maziggy/bambuddy.git
 cd bambuddy
 cd bambuddy
 python3 -m venv venv
 python3 -m venv venv
 source venv/bin/activate
 source venv/bin/activate
 pip install -r requirements.txt
 pip install -r requirements.txt
-
-# Run
 uvicorn backend.app.main:app --host 0.0.0.0 --port 8000
 uvicorn backend.app.main:app --host 0.0.0.0 --port 8000
 ```
 ```
 
 
-Open **http://localhost:8000** and add your printer!
-
-> **Need detailed instructions?** See the [Installation Guide](https://github.com/maziggy/bambuddy-wiki/blob/main/Installation.md)
+> **Need detailed instructions?** See the [Installation Guide](https://github.com/maziggy/bambuddy-wiki/blob/main/Installation.md) or [Docker Guide](https://github.com/maziggy/bambuddy-wiki/blob/main/Docker.md)
 
 
 ### Enabling LAN Mode
 ### Enabling LAN Mode
 
 

+ 3 - 0
build_docker.sh

@@ -0,0 +1,3 @@
+#!/bin/sh
+
+sudo DOCKER_BUILDKIT=0 docker compose build