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

Add hostname parameter to Docker driver #426

Merged
merged 2 commits into from
Nov 17, 2015

Conversation

carlosdp
Copy link
Contributor

This adds the hostname parameter to the Docker driver. This is useful because some service discovery packages, such as Weave, use the hostname to group together containers into a service (in lieu of using the container names, which are unique per host).

@diptanu
Copy link
Contributor

diptanu commented Nov 17, 2015

@carlosdp Won't this result into containers having the same name for TaskGroups with count more than 1? I think you would want the host name to be uniq in the cluster too?

@carlosdp
Copy link
Contributor Author

Not necessarily. when using something like weave, having the same hostname means that container is addressable at that DNS address. So all the postgres containers have the same postgres.weave.local hostname and can be reached on a weave network via DNS as postgres, for example. http://docs.weave.works/weave/latest_release/weavedns.html#usage

@diptanu
Copy link
Contributor

diptanu commented Nov 17, 2015

I see. Can we please make this clear in the docs that setting this would result in all Containers of the Task groups to have the same host name?

@diptanu
Copy link
Contributor

diptanu commented Nov 17, 2015

This LGTM, @dadgar and @cbednarski any thoughts?

@carlosdp
Copy link
Contributor Author

@diptanu done!

@diptanu
Copy link
Contributor

diptanu commented Nov 17, 2015

@carlosdp Thanks!

@dadgar
Copy link
Contributor

dadgar commented Nov 17, 2015

LGTM

dadgar added a commit that referenced this pull request Nov 17, 2015
Add hostname parameter to Docker driver
@dadgar dadgar merged commit 6f6696f into hashicorp:master Nov 17, 2015
@carlosdp carlosdp deleted the hostname-docker branch November 17, 2015 21:02
@github-actions
Copy link

github-actions bot commented May 3, 2023

I'm going to lock this pull request because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants