What is the best practice for deploying docker containers with the selenium/standalone-chrome image?

113 views
Skip to first unread message

Charles Green

unread,
Aug 10, 2017, 1:10:49 AM8/10/17
to Selenium Users
Hello, 

I'm using Selenium WebDriver in Python and the standalone-chrome docker image to scrape data on a JavaScript heavy website. 
I've been able to successfully run my code locally using an instance of the standalone-chrome docker image.
My next step is to deploy it using docker on a remote server and then eventually Amazon ECS. 

I'm not sure what the best practice is for configuration. 

Is it recommended to use the standalone-chrome image as a base image and deploy both the server and my code using a single container or is it better to deploy using two separate containers and configure networking to enable communication between the instances? 

Any resource recommendations would be greatly appreciated. 

Many thanks,
Charles 

Krishnan Mahadevan

unread,
Aug 10, 2017, 1:16:37 AM8/10/17
to seleniu...@googlegroups.com

Charles,

 

I don’t think there are any recommendations to the sort of problem you are dealing with.

 

In a typical automation world, the test code (which is kind of equivalent to your python scraper) would just reside within a version control system, which would be pull down by a build system such as Jenkins or Team city and be executed by the build system.

 

I would suggest that you club your python code and the standalone chrome into the same image. If not anything, I guess its easy to manage.

 

Thanks & Regards

Krishnan Mahadevan

 

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"

My Scribblings @ http://wakened-cognition.blogspot.com/

My Technical Scribbings @ http://rationaleemotions.wordpress.com/

--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/c9d60082-56b8-443d-81e3-9586433a1efe%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Gary @ Qarbon

unread,
Aug 10, 2017, 7:57:29 AM8/10/17
to Selenium Users
Hi Charles,

I suppose one thing you need to consider is how much closer to real life each option is from an architecture point of view. By deploying across two separate containers, are you closer to simulating how the application would work from a network point of view with its associated latencies? It may be with such latencies, some of your tests will respond and work differently? For example, with faster responses from the application, Selenium tests that lack extra synchronisation commands will work but may not with network latency, i.e. slower application responses?

Hope this helps,

Gary
Reply all
Reply to author
Forward
0 new messages