Skip to content

Commit 2fc3919

Browse files
edmundluongphiltrep
authored andcommitted
Added service container for Selenium standalone with Chrome (laradock#519)
* Added service container for Selenium standalone with Chrome
1 parent 978dd42 commit 2fc3919

3 files changed

Lines changed: 23 additions & 0 deletions

File tree

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ Laradock is configured to run Laravel Apps by default, and it can be modified to
5353
- [Use phpMyAdmin](#Use-phpMyAdmin)
5454
- [Use pgAdmin](#Use-pgAdmin)
5555
- [Use ElasticSearch](#Use-ElasticSearch)
56+
- [Use Selenium](#Use-Selenium)
5657
- [CodeIgniter](#CodeIgniter):
5758
- [Install CodeIgniter](#Install-CodeIgniter)
5859
- [Misc](#Misc)
@@ -1058,7 +1059,17 @@ docker exec {container-name} /usr/share/elasticsearch/bin/plugin install delete-
10581059
docker restart {container-name}
10591060
```
10601061

1062+
<br>
1063+
<a name="Use-Selenium"></a>
1064+
### Use Selenium
1065+
1066+
1 - Run the Selenium Container (`selenium`) with the `docker-compose up` command. Example:
1067+
1068+
```bash
1069+
docker-compose up -d selenium
1070+
```
10611071

1072+
2 - Open your browser and visit the localhost on port **4444** at the following URL: `http://localhost:4444/wd/hub`
10621073

10631074

10641075

docker-compose.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -324,6 +324,13 @@ services:
324324
links:
325325
- php-fpm
326326

327+
### Selenium Container #########################################
328+
329+
selenium:
330+
build: ./selenium
331+
ports:
332+
- "4444:4444"
333+
327334
### Volumes Setup ###########################################
328335

329336
volumes:

selenium/Dockerfile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
FROM selenium/standalone-chrome
2+
3+
MAINTAINER Edmund Luong <edmundvmluong@gmail.com>
4+
5+
EXPOSE 4444

0 commit comments

Comments
 (0)