You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 24, 2022. It is now read-only.
`Dockerfile` for running Nginx HTTP server with PHP FPM:
70
70
71
71
```Dockerfile
72
-
FROM phpearth/php:7.2-nginx
72
+
FROM phpearth/php:7.3-nginx
73
73
```
74
74
75
75
Build Docker image and run Docker container:
@@ -92,7 +92,7 @@ docker run -it --rm -v `pwd`:/usr/src/myapp -w /usr/src/myapp phpearth/php php s
92
92
To install Composer:
93
93
94
94
```Dockerfile
95
-
FROM phpearth/php:7.2-nginx
95
+
FROM phpearth/php:7.3-nginx
96
96
97
97
RUN apk add --no-cache composer
98
98
```
@@ -102,7 +102,7 @@ RUN apk add --no-cache composer
102
102
To install PHPUnit:
103
103
104
104
```Dockerfile
105
-
FROM phpearth/php:7.2-nginx
105
+
FROM phpearth/php:7.3-nginx
106
106
107
107
RUN apk add --no-cache phpunit
108
108
```
@@ -112,31 +112,31 @@ RUN apk add --no-cache phpunit
112
112
To run OpenLiteSpeed web server:
113
113
114
114
```Dockerfile
115
-
FROM phpearth/php:7.2-litespeed
115
+
FROM phpearth/php:7.3-litespeed
116
116
```
117
117
118
118
### Lighttpd
119
119
120
120
To run Lighttpd web server:
121
121
122
122
```Dockerfile
123
-
FROM phpearth/php:7.2-lighttpd
123
+
FROM phpearth/php:7.3-lighttpd
124
124
```
125
125
126
126
### PHP extensions
127
127
128
128
To install additional PHP extensions, you can use packages from the [PHP.earth Alpine repository](https://docs.php.earth/linux/alpine):
129
129
130
130
```Dockerfile
131
-
FROM phpearth/php:7.2-nginx
131
+
FROM phpearth/php:7.3-nginx
132
132
133
-
RUN apk add --no-cache php7.2-sodium php7.2-intl php7.2-pdo_mysql
133
+
RUN apk add --no-cache php7.3-sodium php7.3-intl php7.3-pdo_mysql
134
134
```
135
135
136
136
or install them with `pecl`:
137
137
138
138
```bash
139
-
apk add --no-cache php7.2-dev gcc g++
139
+
apk add --no-cache php7.3-dev gcc g++
140
140
pecl install {extension-name}
141
141
```
142
142
@@ -146,10 +146,10 @@ In case you'd need an additional extension in the PHP.earth repository, [open an
146
146
147
147
### Docker Stack
148
148
149
-
Docker Stack is way of orchestration of Docker services and simplifies running multiple services of your application. In this example we'll run an Nginx web server with PHP 7.2 FPM with `docker-compose.yml` file. In a new project directory create a `Dockerfile`:
149
+
Docker Stack is way of orchestration of Docker services and simplifies running multiple services of your application. In this example we'll run an Nginx web server with PHP 7.3 FPM with `docker-compose.yml` file. In a new project directory create a `Dockerfile`:
And there should be `phpinfo()` output visible on `http://localhost`. Make sure there isn't any other service listening on port 80 before running above command.
191
191
192
-
### PHP 7.0 and PHP 7.1
192
+
### PHP 7.0, 7.1, PHP 7.2
193
193
194
-
To use PHP 7.0or 7.1 use Docker images with `7.0`or `7.1`:
194
+
To use older versions PHP 7.0, 7.1, or 7.2 use Docker images with `7.0`, `7.1`, or `7.2`:
0 commit comments