DeFactOfficial commited on
Commit
93044eb
·
verified ·
1 Parent(s): 9b90693

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +13 -8
Dockerfile CHANGED
@@ -101,8 +101,11 @@ EOF
101
 
102
  RUN ln -s /etc/nginx/sites-available/reverse-proxy.conf /etc/nginx/sites-enabled/
103
 
104
- # Create startup script with HF Spaces specific considerations
105
- COPY <<-'EOF' $HOME/code/start.sh
 
 
 
106
  #!/bin/bash
107
 
108
  # Print environment info for debugging
@@ -114,9 +117,6 @@ echo "====================="
114
  echo "Stopping old services..."
115
  pm2 delete all
116
 
117
- # start the imaging + tts api
118
- echo "Starting the API"
119
- cd $HOME/code && pm2 start api.js
120
 
121
  # Start all services in background with logging
122
  #cd /code/service1 && ./run.sh > /var/log/service1.log 2>&1 &
@@ -135,12 +135,17 @@ pm2 list
135
 
136
  # Start nginx in foreground
137
  nginx -g 'daemon off;'
138
- EOF
139
 
140
 
 
 
 
 
 
 
141
  #make our shell script runnable
142
- RUN chmod +x $HOME/code/start.sh
143
 
144
  # Start everything
145
- CMD ["$HOME/code/start.sh"]
146
  #ENTRYPOINT ["nodejs", "./api.js"]
 
101
 
102
  RUN ln -s /etc/nginx/sites-available/reverse-proxy.conf /etc/nginx/sites-enabled/
103
 
104
+ # Claude wanted to dynamically write out a script then run it...
105
+ # but it goes against defact principles of readable code
106
+ # so no
107
+
108
+ # COPY <<-'EOF' $HOME/code/start.sh
109
  #!/bin/bash
110
 
111
  # Print environment info for debugging
 
117
  echo "Stopping old services..."
118
  pm2 delete all
119
 
 
 
 
120
 
121
  # Start all services in background with logging
122
  #cd /code/service1 && ./run.sh > /var/log/service1.log 2>&1 &
 
135
 
136
  # Start nginx in foreground
137
  nginx -g 'daemon off;'
 
138
 
139
 
140
+ # start the imaging + tts api
141
+ echo "Starting the API"
142
+ #ENTRYPOINT ["nodejs", "./api.js"]
143
+
144
+ cd $HOME/code && pm2 start api.js
145
+
146
  #make our shell script runnable
147
+ #RUN chmod +x $HOME/code/start.sh
148
 
149
  # Start everything
150
+ #CMD ["$HOME/code/start.sh"]
151
  #ENTRYPOINT ["nodejs", "./api.js"]