Crates.io | soda-test-service |
lib.rs | soda-test-service |
version | 0.1.1 |
source | src |
created_at | 2019-02-06 15:21:13.625642 |
updated_at | 2019-02-07 13:51:58.295737 |
description | SODA Test Service helps with tracking test sessions |
homepage | |
repository | https://github.com/voyages-sncf-technologies/soda-test-service |
max_upload_size | |
id | 113159 |
size | 36,592 |
The test service is a microservice belonging to the project Selenium On Demand Acronym. It acts like a reverse proxy in front of your Selenium hub. The test service is useful to :
These instructions will get you a minimal Selenium Grid with :
AUTH_USER=user AUTH_PWD=pwd docker-compose up -d
Copy the following snippet to add the test service in your docker-compose file and customize it as you want. It's fully compatible with the official repositories of SeleniumHQ/docker-selenium.
Note that you need to replace the values of AUTH_USER
and AUTH_PWD
by your owns :
test-service:
image: soda/test-service:latest
ports:
- "8080:8080"
environment:
- HUB_PORT_4444_TCP_ADDR=hub
- HUB_PORT_4444_TCP_PORT=4444
- AUTH_USER=my_user
- AUTH_PWD=my_user_pwd
networks:
- your-selenium-network
Then run your services with the following docker-compose command :
# Equivalent to docker-compose up -d test-service hub chrome firefox
docker-compose up -d
Finally use the Selenium hub through the test-service : http://<AUTH_USER>:<AUTH_PWD>@localhost:8080
Pro tip : when you're developing, always use
cargo check
to avoid long build times. Then, when you are ready to test your work, usecargo run
which will build a non-optimized binary and launch it.
# Launch the Selenium hub with chrome and firefox on localhost:4444
docker-compose up -d hub chrome firefox
# Launch the test service on localhost:8080 and forward requests to the hub
# Arguments : <LISTEN ADDR> <LISTEN PORT> <FWD ADDR> <FWD PORT>
AUTH_USER=user AUTH_PWD=pwd cargo run localhost 8080 localhost 4444
This project is licensed under either of
at your option.
Your contribution is welcome! You can found more information in the CONTRIBUTING.md.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you shall be dual licensed as above, without any additional terms or conditions.