mirror of
https://github.com/burakkaygusuz/selenium-4-grid-k8s-docker.git
synced 2021-06-27 00:03:24 +03:00
Project name changed
This commit is contained in:
63
README.md
63
README.md
@@ -1,43 +1,28 @@
|
||||
# Selenium Automation Architecture
|
||||
|
||||
This demo that created as a template, demonstrates how to do the settings of the Chrome ve Firefox web driver for distributed parallel testing with Selenium 4 Grid using Kubernetes and Docker.
|
||||
# Selenium 4 Grid & K8s & Docker
|
||||
|
||||
This demo that created as a template, demonstrates how to do the settings of the Chrome ve Firefox web driver for
|
||||
distributed parallel testing with Selenium 4 Grid using Kubernetes and Docker.
|
||||
|
||||
## Requirements
|
||||
|
||||
- This project requires [Java 11 JDK](https://adoptopenjdk.net/).
|
||||
- Install [Docker](https://www.docker.com/) for parallel testing.
|
||||
- Install [Kubectl](https://kubernetes.io/docs/tasks/tools/install-kubectl/), Kubernetes command-line tool. (This item is optional. **kubectl.exe** is added with Docker installation.)
|
||||
- Install [Minikube](https://kubernetes.io/docs/setup/learning-environment/minikube/) to run Kubernetes as locally.
|
||||
- Specify any VM driver appropriate for your OS. Review the doc for driver list : [https://minikube.sigs.k8s.io/docs/drivers/](https://minikube.sigs.k8s.io/docs/drivers/)
|
||||
|
||||
## Commands
|
||||
|
||||
- Start the minikube.
|
||||
```sh
|
||||
$ minikube start
|
||||
```
|
||||
- Create the deployment.
|
||||
```sh
|
||||
$ kubectl create -f deploy.yml
|
||||
```
|
||||
- Check the details of deployment.
|
||||
```sh
|
||||
$ kubectl describe deploy.yml
|
||||
```
|
||||
- Create the service.
|
||||
```sh
|
||||
$ kubectl create -f service.yml
|
||||
```
|
||||
- Check the details of services and reach the hub URL in the Endpoints section with the port number in the NodePort section. Add that values in URL methods of **DriverFactory** class.
|
||||
```sh
|
||||
$ kubectl describe service
|
||||
```
|
||||
- Create the replication controller(s).
|
||||
```sh
|
||||
$ kubectl create -f repchrome.yml
|
||||
```
|
||||
- Get all created pods.
|
||||
```sh
|
||||
$ kubectl get pods
|
||||
```
|
||||
- This project requires [Java 11 JDK](https://adoptopenjdk.net/).
|
||||
- Install [Docker](https://www.docker.com/) for parallel testing.
|
||||
- Install [Kubectl](https://kubernetes.io/docs/tasks/tools/install-kubectl/), Kubernetes command-line tool. (This item
|
||||
is optional. **kubectl.exe** is added with Docker installation.)
|
||||
- Install [Minikube](https://kubernetes.io/docs/setup/learning-environment/minikube/) to run Kubernetes as locally.
|
||||
- Specify any VM driver appropriate for your OS. Review the doc for driver
|
||||
list : [https://minikube.sigs.k8s.io/docs/drivers/](https://minikube.sigs.k8s.io/docs/drivers/)
|
||||
|
||||
### Deploying the Kubernetes
|
||||
|
||||
```shell
|
||||
|
||||
# Deploying all the grid components to kubernetes
|
||||
$ kubectl apply -f deploy.yml
|
||||
|
||||
# Exposing the router
|
||||
$ kubectl expose deployment selenium-router-deployment --type=NodePort --port=4444
|
||||
|
||||
# Get the router URL to access the grid from outside K8s cluster
|
||||
$ minikube service selenium-router-deployment --url
|
||||
```
|
||||
|
||||
@@ -10,7 +10,7 @@ version '1.0'
|
||||
sourceCompatibility = JavaVersion.VERSION_11
|
||||
targetCompatibility = JavaVersion.VERSION_11
|
||||
|
||||
description = "Selenium Automation Architecture"
|
||||
description = "Selenium 4 Grid & K8s & Docker"
|
||||
compileJava.options.encoding = 'UTF-8'
|
||||
|
||||
repositories {
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
rootProject.name = 'Selenium Automation Architecture'
|
||||
rootProject.name = 'selenium-4-grid-k8s-docker'
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ Configuration:
|
||||
|
||||
RollingFile:
|
||||
- name: LogToRollingFile
|
||||
fileName: logs/selenium_automation_architecture.log
|
||||
fileName: logs/selenium_4_grid_k8s_docker.log
|
||||
filePattern: "logs/$${date:yyyy-MM}/app-%d{MM-dd-yyyy}-%i.log.gz"
|
||||
PatternLayout:
|
||||
pattern: "[%-5level] %d{yyyy-MM-dd | HH:mm:ss} | %c{1} | %msg%n"
|
||||
|
||||
Reference in New Issue
Block a user