screenshot-to-code Docker & Self-Hosted Deployment

GitHub

Drop in a screenshot and convert it to clean code (HTML/Tailwind/React/Vue)

73,781 stars Python Python 1 file ยท ~1,810 tokens
RAW Compose
1. Pull Image (DOCKERHUB) docker pull abi/screenshot-to-code
2. Docker Run (1-Click Launch) docker run -d --name screenshot-to-code -p 5173:5173 --restart always abi/screenshot-to-code:latest
3. Podman Run podman run -d --name screenshot-to-code -p 5173:5173 --restart always abi/screenshot-to-code:latest
4. Skopeo Inspect (Zero-Pull Manifest) skopeo inspect docker://docker.io/abi/screenshot-to-code:latest
5. ORAS Pull (OCI Artifact) oras pull abi/screenshot-to-code:latest
6. Compose Deployment docker compose up -d
docker-compose.yml
Download .yml
version: '3.9'

services:
  backend:
    build: 
      context: ./backend
      dockerfile: Dockerfile
    
    env_file:
      - .env
    
    # or 
    # environment:
      #- BACKEND_PORT=7001   # if you change the port, make sure to also change the VITE_WS_BACKEND_URL at frontend/.env.local
      # - OPENAI_API_KEY=your_openai_api_key
    
    ports:
      - "${BACKEND_PORT:-7001}:${BACKEND_PORT:-7001}"

    command: poetry run uvicorn main:app --host 0.0.0.0 --port ${BACKEND_PORT:-7001}
  
  frontend:
    build:
      context: ./frontend
      dockerfile: Dockerfile
    ports:
      - "5173:5173"