magicudapps commited on
Commit
587bde8
1 Parent(s): 3535e94

feat: add Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +18 -0
Dockerfile ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM python:3.11.9
2
+
3
+ RUN useradd -m -u 1000 user
4
+ USER user
5
+ ENV HOME=/home/user \
6
+ PATH=/home/user/.local/bin:$PATH
7
+ WORKDIR $HOME/app
8
+
9
+ RUN --mount=type=secret,id=GITLAB_CREDENTIALS,mode=0444,required=true \
10
+ git clone "https://$(cat /run/secrets/GITLAB_CREDENTIALS)@gitlab.com/bookingcare/search.git" -b dev .
11
+ RUN python -m pip install --upgrade pip
12
+ RUN pip install --user pipenv
13
+ RUN echo 'export PATH="/home/user/.local/bin:$PATH"' >> $HOME/.bashrc
14
+ RUN . $HOME/.bashrc
15
+ RUN pipenv install
16
+
17
+ EXPOSE 7860
18
+ CMD ["sh", "bin/hf-api-start.sh"]