geethareddy commited on
Commit
9b771a5
·
verified ·
1 Parent(s): 44aa01c

Update dockerfile

Browse files
Files changed (1) hide show
  1. dockerfile +21 -37
dockerfile CHANGED
@@ -1,16 +1,8 @@
1
- FROM docker.io/library/python:3.10@sha256:875c3591e586f66aa65621926230925144920c951902a6c2eef005d9783a7ca7
2
-
3
- COPY --chown=1000:1000 --from=root / /
4
- WORKDIR /home/user/app
5
-
6
- RUN apt-get update && apt-get install -y fakeroot && \
7
- mv /usr/bin/apt-get /usr/bin/.apt-get && \
8
- echo '#!/usr/bin/env sh\nfakeroot /usr/bin/.apt-get $@' > /usr/bin/apt-get && \
9
- chmod +x /usr/bin/apt-get && \
10
- rm -rf /var/lib/apt/lists/* && \
11
- useradd -m -u 1000 user
12
 
 
13
  RUN apt-get update && apt-get install -y \
 
14
  git \
15
  git-lfs \
16
  ffmpeg \
@@ -19,35 +11,27 @@ RUN apt-get update && apt-get install -y \
19
  cmake \
20
  rsync \
21
  libgl1-mesa-glx \
 
 
 
 
 
 
22
  && rm -rf /var/lib/apt/lists/* \
23
  && git lfs install
24
 
25
- RUN pip install --no-cache-dir pip -U && \
26
- pip install --no-cache-dir \
27
- datasets \
28
- "huggingface-hub>=0.19" \
29
- "hf_xet>=1.0.0,<2.0.0" \
30
- "hf-transfer>=0.1.4" \
31
- "protobuf<4" \
32
- "click<8.1" \
33
- "pydantic~=1.0"
34
-
35
- RUN apt-get update && \
36
- apt-get install -y curl && \
37
- curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \
38
- apt-get install -y nodejs && \
39
- rm -rf /var/lib/apt/lists/* && apt-get clean
40
 
41
- COPY requirements.txt /tmp/requirements.txt
42
- RUN pip install --no-cache-dir -r /tmp/requirements.txt
 
 
43
 
44
- COPY . .
45
- ENV GEMINI_API_KEY="your_gemini_api_key_here" # Replace with your actual Gemini API key
46
- ENV SF_USERNAME="[email protected]"
47
- ENV SF_PASSWORD="voicebot1"
48
- ENV SF_SECURITY_TOKEN="jq4VVHUFti6TmzJDjjegv2h6b"
49
- ENV SF_INSTANCE_URL="https://swe42.sfdc-cehfhs.salesforce.com"
50
- ENV ENCRYPTION_KEY=$(python -c "from cryptography.fernet import Fernet; print(Fernet.generate_key().decode())")
51
- ENV SALESFORCE_USER_EMAIL="[email protected]"
52
 
53
- CMD ["python", "app.py"]
 
 
1
+ FROM python:3.10
 
 
 
 
 
 
 
 
 
 
2
 
3
+ # Install system dependencies
4
  RUN apt-get update && apt-get install -y \
5
+ fakeroot \
6
  git \
7
  git-lfs \
8
  ffmpeg \
 
11
  cmake \
12
  rsync \
13
  libgl1-mesa-glx \
14
+ espeak \
15
+ libespeak1 \
16
+ curl \
17
+ nodejs \
18
+ && curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \
19
+ && apt-get install -y nodejs \
20
  && rm -rf /var/lib/apt/lists/* \
21
  && git lfs install
22
 
23
+ # Create user
24
+ RUN useradd -m -u 1000 user
25
+ WORKDIR /home/user/app
26
+ USER user
 
 
 
 
 
 
 
 
 
 
 
27
 
28
+ # Install Python dependencies
29
+ COPY requirements.txt .
30
+ RUN pip install --no-cache-dir pip -U && \
31
+ pip install --no-cache-dir -r requirements.txt
32
 
33
+ # Copy application code
34
+ COPY --chown=1000:1000 . .
 
 
 
 
 
 
35
 
36
+ # Run application
37
+ CMD ["python", "voice_health_analyzer.py"]