Skip to content

Conversation

@markjgardner
Copy link

Added a few best practices and minor improvements to your package.json example.

@simonua
Copy link
Owner

simonua commented Feb 23, 2022

Thank you, @markjgardner! I'll look this over to understand it better and incorporate.


# 7) Execute the script in NodeJS
CMD ["node", "runtest.js"]
CMD ["node", "app/runtest.js"]
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@markjgardner, what is the process of updating runtest.js in the volume?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The point of putting it in a volume is that it is decoupled from the container. The assumption is that your test will change (much) more frequently than your chrome or selenium versions. So you can just publish new tests to the volume and restart the container vs having to build and publish a new image.

How you update the tests is up to you and dependent on how you are going to run this container. If it is for local development, then just using a bind mount per example.sh will let you work locally on the tests and just do a docker run ... whenever you want to validate. If, however, you want to run this container in k8s, then you would likely have a CD pipeline that pushed your tests to a blob container or file share which was subsequently mounted to the pods.

Make sense?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, definitely. I'll pursue this further. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants