Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 4bf1a2d

Browse files
Update README.md
1 parent 1528a0a commit 4bf1a2d

File tree

1 file changed

+42
-1
lines changed

1 file changed

+42
-1
lines changed

‎README.md

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,50 @@
22

33
A basic example of setting up a LAMP stack from scratch using Docker.
44

5+
```yml
6+
version: '3'
7+
services:
8+
db:
9+
image: mysql:latest
10+
environment:
11+
MYSQL_DATABASE: lamp_demo
12+
MYSQL_USER: lamp_demo
13+
MYSQL_PASSWORD: password
14+
MYSQL_ALLOW_EMPTY_PASSWORD: 1
15+
volumes:
16+
- "./db:/docker-entrypoint-initdb.d"
17+
networks:
18+
- lamp-docker
19+
www:
20+
depends_on:
21+
- db
22+
image: php:8.1.1-apache
23+
volumes:
24+
- "./:/var/www/html"
25+
ports:
26+
- 80:80
27+
- 443:443
28+
networks:
29+
- lamp-docker
30+
phpmyadmin:
31+
depends_on:
32+
- db
33+
image: phpmyadmin/phpmyadmin
34+
ports:
35+
- 8001:80
36+
environment:
37+
- PMA_HOST=db
38+
- PMA_PORT=3306
39+
networks:
40+
- lamp-docker
41+
networks:
42+
lamp-docker:
43+
driver: bridge
44+
```
45+
546
## Tutorial Requirements:
647
7-
* [Visual Studio Code](https://code.visualstudio.com/) or [Brackets](http://brackets.io/) (or any code editor)
48+
* [Visual Studio Code](https://code.visualstudio.com/)
849
* [Docker](https://www.docker.com/)
950
1051
<a href="https://codeadam.ca">

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /