File size: 941 Bytes
cbacb69
e5f0488
cbacb69
 
e5f0488
cbacb69
e5f0488
cbacb69
 
 
 
 
 
 
d612e2e
 
 
cbacb69
 
 
 
 
 
e5f0488
cb999e9
cbacb69
 
cb999e9
e5f0488
cb999e9
cbacb69
e5f0488
cb999e9
cbacb69
01da718
cbacb69
01da718
cbacb69
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
FROM python:3.9-slim-buster

RUN apt-get update && \
	apt-get install -y git

RUN useradd -m -u 1000 user

# Switch to the "user" user
USER user

# Set home to the user's home directory
ENV HOME=/home/user \
	PATH=/home/user/.local/bin:$PATH

# RUN git clone https://github.com/jtsang4/claude-to-chatgpt.git $HOME/app

RUN git clone https://github.com/SimFG/claude-to-chatgpt.git $HOME/app

# Set the working directory to the user's home directory
WORKDIR $HOME/app

# Copy the current directory contents into the container at $HOME/app setting the owner to the user
COPY --chown=user . $HOME/app

# Set the environment variables
ENV CLAUDE_BASE_URL="https://api.anthropic.com"
ENV LOG_LEVEL="info"
ENV PORT=7860

# Install Poetry
RUN pip install --user poetry

# Expose the port the app runs on
EXPOSE 7860

RUN poetry install --only main

# Set the command to run the application
CMD ["poetry", "run", "python", "claude_to_chatgpt/app.py"]