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 address config option to specify host:port #305

Closed
crvcrv opened this issue Dec 11, 2019 · 3 comments
Closed

Add address config option to specify host:port #305

crvcrv opened this issue Dec 11, 2019 · 3 comments
Labels

Comments

@crvcrv
Copy link

crvcrv commented Dec 11, 2019

Add a config option to specify host:post.
Currently one can only set the port via config option Port just for krakend to use this value as a string.

func NewServer(cfg config.ServiceConfig, handler http.Handler) *http.Server {
	return &http.Server{
		Addr:              fmt.Sprintf(":%d", cfg.Port),
                ...
	}
}

See https://github.com/devopsfaith/krakend/blob/master/transport/http/server/server.go#L107

Solution: Add an Address config option that should bind stronger than Port does so if Port and Address is specified Address is being used.

crvcrv pushed a commit to crvcrv/krakend that referenced this issue Dec 11, 2019
added config option Address to config + tests
added config parsing if Address and Port are specified + tests
added using Address config option in server + tests
@dhontecillas
Copy link
Contributor

this PR: #695 should fix the issue

@alombarte
Copy link
Member

Released

Copy link

This issue was marked as resolved a long time ago and now has been automatically locked as there has not been any recent activity after it. You can still open a new issue and reference this link.

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

No branches or pull requests

3 participants