Spaces:
Runtime error
Runtime error
# Use an official Ubuntu as a parent image | |
FROM ubuntu:latest | |
# Set the working directory to /app | |
WORKDIR /app | |
# Update the package list and install necessary packages | |
RUN apt-get update && \ | |
apt-get install -y git wget curl build-essential && \ | |
rm -rf /var/lib/apt/lists/* | |
# clone one git repo | |
RUN git clone "https://github.com/antimatter15/alpaca.cpp.git" | |
# cd into alpaca.cpp folder and run make command | |
RUN cd alpaca.cpp && make && cd .. | |
RUN wget "https://huggingface.co/sosaka/alpaca-native-4bit-ggml/resolve/main/ggml-alpaca-7b-q4.bin" | |
# copy the chat file to /app | |
RUN cp alpaca.cpp/chat . | |
# remove the alpaca.cpp folder | |
RUN rm -rf alpaca.cpp | |
# Copy the package.json and package-lock.json files to the container | |
COPY package*.json ./ | |
# Install the dependencies and Node.js | |
RUN curl -sL https://deb.nodesource.com/setup_18.x | bash - | |
RUN apt-get install -y nodejs | |
RUN npm install -g [email protected] && npm install && rm -rf /var/lib/apt/lists/* | |
# Copy the rest of the application files to the container | |
COPY . . | |
# Build the Vite app | |
RUN npm run build | |
# Expose port 8889 for the Express app | |
EXPOSE 8889 | |
# Start the Express app | |
CMD ["npm", "start"] | |