keshavbhandari commited on
Commit
d102425
1 Parent(s): e198246

testing dockerfile

Browse files
Files changed (3) hide show
  1. Dockerfile +17 -0
  2. Dockerfile_archive.txt +0 -30
  3. setup.txt +1 -3
Dockerfile ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use the base image
2
+ FROM continuumio/anaconda3:main
3
+
4
+ # Install fluidsynth
5
+ RUN apt-get update && apt-get install -y fluidsynth
6
+
7
+ # Copy the current directory contents into the container
8
+ COPY . /app
9
+
10
+ # Set the working directory
11
+ WORKDIR /app
12
+
13
+ # Install Python dependencies
14
+ RUN pip install -r requirements.txt
15
+
16
+ # Command to run your application (adjust as needed)
17
+ CMD ["python", "app.py"]
Dockerfile_archive.txt DELETED
@@ -1,30 +0,0 @@
1
- FROM continuumio/anaconda3:main
2
-
3
- WORKDIR /code
4
- COPY ./environment.yml /code/environment.yml
5
-
6
- # Create the environment using the environment.yml file
7
- RUN conda env create -f /code/environment.yml && \
8
- conda run -n myenv conda install -c conda-forge fluidsynth -y
9
-
10
- # Set up a new user named "user" with user ID 1000
11
- RUN useradd -m -u 1000 user
12
- # Switch to the "user" user
13
- USER user
14
- # Set home to the user's home directory
15
- ENV HOME=/home/user \
16
- PYTHONPATH=$HOME/app \
17
- PYTHONUNBUFFERED=1 \
18
- GRADIO_ALLOW_FLAGGING=never \
19
- GRADIO_NUM_PORTS=1 \
20
- GRADIO_SERVER_NAME=0.0.0.0 \
21
- GRADIO_THEME=huggingface \
22
- SYSTEM=spaces
23
-
24
- # Set the working directory to the user's home directory
25
- WORKDIR $HOME/app
26
-
27
- # Copy the current directory contents into the container at $HOME/app setting the owner to the user
28
- COPY --chown=user . $HOME/app
29
-
30
- CMD ["./run.sh"]
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
setup.txt CHANGED
@@ -4,6 +4,4 @@ install_requires = []
4
  if os.path.isfile(requirement_path):
5
  with open(requirement_path) as f:
6
  install_requires = f.read().splitlines()
7
- setup(name="mypackage", install_requires=install_requires, [...])
8
-
9
- apt-get update && apt-get install -y fluidsynth
 
4
  if os.path.isfile(requirement_path):
5
  with open(requirement_path) as f:
6
  install_requires = f.read().splitlines()
7
+ setup(name="mypackage", install_requires=install_requires, [...])