Spaces:
Paused
Paused
File size: 568 Bytes
2c54ff5 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y \
curl \
wget \
ca-certificates \
&& rm -rf /var/lib/apt/lists/*
RUN wget -O /usr/local/bin/opencode2api \
https://github.com/dsadsadsss/Opencodeai/releases/download/2/opencode2api-linux-amd64 \
&& chmod +x /usr/local/bin/opencode2api
RUN cat > /start.sh << 'EOF'
#!/bin/bash
set -e
echo "[1/2] Starting opencode2api on :7860 ..."
/usr/local/bin/opencode2api --password "$PASSWORD" --port 7860
EOF
RUN chmod +x /start.sh
EXPOSE 7860
CMD ["/start.sh"] |