Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use docker to run services #13

Open
thedrow opened this issue Oct 11, 2015 · 1 comment
Open

Use docker to run services #13

thedrow opened this issue Oct 11, 2015 · 1 comment

Comments

@thedrow
Copy link
Contributor

thedrow commented Oct 11, 2015

Docker can be used to run the different components that are being tested.
It will help with installation and with running the test suite more consistently.

@crdoconnor
Copy link
Contributor

Have you noticed any specific inconsistencies?

Installation-wise I don't think it would help much. Hitch already substantially isolates the components by downloading and compiling them itself in their own directories. You can specify the same version of postgres that you intend to use in production, for instance, and that one will be downloaded and compiled and run with your code. That eliminates the largest source of inconsistency.

If your coworker's laptop's package manager has a different version postgres or python it doesn't matter, for instance. Hitch will be building and using its own.

Docker does give slightly more isolation than hitch does, but actually not all that much more and probably not enough to make integration worth it. Docker also doesn't (AFAIK) isolate you from the kernel version or libc version, for instance, and differences in both of those can cause inconsistent behavior. It also doesn't work on Mac OS without a VM (last I heard, anyway).

To test as close as consistent behavior with what you have running in production, I'd suggest periodically running your hitch tests in an environment that is as close as possible to the environment you run in production - same OS, same OS version, same kernel, same libc, same system libraries. That will either help detect additional production-environment specific bugs or give you additional confidence that your code will work as expected once it hits production (if everything passes).

However, for every-day development that level of isolation and testing is overkill and will slow you down.

I'll also probably be adding a docker plugin at some point so if you have additional services which you really want to run in docker, you will be able to.

Note that you can run hitch in docker as well, if you like. I tried it and it seems to work.

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

No branches or pull requests

2 participants