Shinhati2023 commited on
Commit
03a971f
·
verified ·
1 Parent(s): aac897e

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +15 -17
Dockerfile CHANGED
@@ -1,30 +1,28 @@
1
- # We use the Alpine-XFCE version for a very lightweight "small linux" footprint
2
- FROM linuxserver/webtop:alpine-xfce
3
 
4
  # --------------------------------------------------------
5
- # CONFIGURATION FOR HUGGING FACE
6
  # --------------------------------------------------------
7
-
8
- # Hugging Face Spaces expect the application to run on port 7860.
9
- # Webtop defaults to 3000, so we modify the internal Nginx config to listen on 7860.
10
  RUN sed -i 's/3000/7860/g' /defaults/nginx.conf
11
 
12
- # Set the User ID to 1000 (Hugging Face default user) to avoid permission issues
13
  ENV PUID=1000
14
  ENV PGID=1000
15
 
16
- # Set Timezone (Optional, change if needed)
17
- ENV TZ=Etc/UTC
18
-
19
  # --------------------------------------------------------
20
- # OPTIONAL: PRE-INSTALL APPS
21
  # --------------------------------------------------------
22
- # You can install apps here so they exist every time the space restarts.
23
- # Example: Installing Python3, Git, and Firefox
24
- RUN apk add --no-cache \
25
  python3 \
26
- py3-pip \
27
  git \
28
- firefox
 
 
 
 
29
 
30
- # The container entrypoint handles the rest!
 
1
+ # We are switching to 'ubuntu-xfce' because 'alpine-xfce' is not valid
2
+ FROM linuxserver/webtop:ubuntu-xfce
3
 
4
  # --------------------------------------------------------
5
+ # CONFIGURATION
6
  # --------------------------------------------------------
7
+ # Change port from 3000 to 7860 for Hugging Face
 
 
8
  RUN sed -i 's/3000/7860/g' /defaults/nginx.conf
9
 
10
+ # Set User permissions
11
  ENV PUID=1000
12
  ENV PGID=1000
13
 
 
 
 
14
  # --------------------------------------------------------
15
+ # PRE-INSTALL APPS (The "Memory" Part)
16
  # --------------------------------------------------------
17
+ # Since we switched to Ubuntu, we use 'apt-get' instead of 'apk'
18
+ RUN apt-get update && apt-get install -y \
 
19
  python3 \
20
+ python3-pip \
21
  git \
22
+ firefox \
23
+ nano \
24
+ vlc \
25
+ # Add any other apps here
26
+ && apt-get clean
27
 
28
+ # The container entrypoint handles the startup