chartManD commited on
Commit
ca7d3ba
·
1 Parent(s): 07b5682

php corre index sin alojamineto

Browse files
Files changed (1) hide show
  1. Dockerfile +18 -7
Dockerfile CHANGED
@@ -11,15 +11,26 @@
11
  # COPY index.php index.php
12
  # CMD ["php", "-S", "localhost:7680", "./index.php"]
13
 
14
- FROM php:8.0-apache
 
15
 
16
- RUN echo "ServerName localhost" >> /etc/apache2/apache2.conf
17
 
18
- RUN sed -i 's/Listen 80/Listen 8080/' /etc/apache2/ports.conf
19
- RUN sed -i 's/:80/:8080/g' /etc/apache2/sites-available/000-default.conf
20
 
21
- COPY . /var/www/html/
 
22
 
23
- EXPOSE 8080
24
 
25
- CMD ["apache2-foreground"]
 
 
 
 
 
 
 
 
 
 
 
11
  # COPY index.php index.php
12
  # CMD ["php", "-S", "localhost:7680", "./index.php"]
13
 
14
+ #################
15
+ #----------------------
16
 
17
+ # FROM php:8.0-apache
18
 
19
+ # RUN echo "ServerName localhost" >> /etc/apache2/apache2.conf
 
20
 
21
+ # RUN sed -i 's/Listen 80/Listen 8080/' /etc/apache2/ports.conf
22
+ # RUN sed -i 's/:80/:8080/g' /etc/apache2/sites-available/000-default.conf
23
 
24
+ # COPY . /var/www/html/
25
 
26
+ # EXPOSE 8080
27
+
28
+ # CMD ["apache2-foreground"]
29
+
30
+ #################
31
+ #----------------------
32
+
33
+ FROM php:8.2-cli
34
+ COPY . /usr/src/app
35
+ WORKDIR /usr/src/app
36
+ CMD [ "php", "./index.php" ]