Skip to content

Commit ea8a3fb

Browse files
Update README.md
1 parent 7de3074 commit ea8a3fb

1 file changed

Lines changed: 7 additions & 4 deletions

File tree

README.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,7 @@ docker ps
101101
| 09f51b5f330b | dockerize-existing-drupal-project_apache | "httpd-foreground" | 32 seconds ago | Up 30 seconds | 0.0.0.0:80->80/tcp | apache |
102102
| 8294e1800058 | dockerize-existing-drupal-project_php | "docker-php-entrypoi…" | 33 seconds ago | Up 31 seconds | 9000/tcp | php |
103103
| d8b2cbac5695 | mysql:8.0.0 | "docker-entrypoint.s…" | 33 seconds ago | Up 31 seconds | 0.0.0.0:3306->3306/tcp | mysql |
104+
104105
5. Now jump into the PHP container using the `docker exec` command.
105106
```
106107
docker exec -it 8294e1800058 /bin/sh
@@ -109,13 +110,15 @@ Since you will be using the `root` user inside the container, so you should have
109110
```
110111
/var/www/html # ls
111112
```
112-
If it shows you `index.php` that means it mounts to your local repository i.e. `docroot`
113+
If it shows you `index.php` that means it mounts to your local repository i.e. `docroot`.
114+
113115
6. Now hit the http://localhost:80 in browser to ensure setup is successful. Along with the below output, you will also see phpinfo() output.
114116
```
115117
Congratulations!! Docker setup connection is successful.
116118
Checking MySQL integration with php.
117119
MySql connection is successful!
118120
```
121+
119122
7. Now the docker setup is done, you can put your local codebase inside the `docroot`. Now it's up to you whether you want to run multiple drupal instances within this repository or a single one. If you want to manage multiple repositories then keep the project folder inside the `docroot` repository. For example, in our case, it's `drupal8` repository.
120123

121124
```
@@ -150,14 +153,14 @@ Now this project Drupal's docroot should be located at `/var/www/html/drupal8/we
150153
drush sql:dump --result-file=../backup.sql
151154
```
152155
Here `backup.sql` is your mysql database backup file. It can different in your case.
156+
153157
9. Now access your drupal project in browser. For example, in our case it would be below URL:
154158
```
155159
http://localhost/drupal8/web
156160
```
157-
We may create virtual host entry for above URL.
158-
10.
161+
We may create virtual host entry for above URL. With some browsers and operating systems any path ending in `localhost` will work automatically, otherwise you may need update your hosts file so your browser will know it's a local url.
159162

160-
--WIP---
163+
10. Also to exit from a container, just type `exit` in terminal.
161164

162165
## Issues and Resolutions
163166

0 commit comments

Comments
 (0)