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

LoadBalancer #27

Open
fkautz opened this issue Jul 5, 2016 · 1 comment
Open

LoadBalancer #27

fkautz opened this issue Jul 5, 2016 · 1 comment

Comments

@fkautz
Copy link
Collaborator

fkautz commented Jul 5, 2016

A load balancer config should be created.

One potential approach:

services:
    web:
        ports:
            - "80:8080"

One option may be to use the host port "80" to point to the service port "8080".


A second option would be to add an additional config option specific for compose2kube

e.g.:

services:
    web:
        ports:
            - "8080" # `kube:"LoadBalancerPort:80"`

A third option would be to extract this to a separate config file, which would benefit operational users.

e.g.

services:
    web:
        ports:
            - "8080"

and

loadbalancers:
    web:
        ports:
            - "80:8080"
@fkautz
Copy link
Collaborator Author

fkautz commented Jul 5, 2016

One problem with the first approach is it breaks docker compose's ability to scale on a single system.

docker-compose scale web=10

Each replicated container will fail to start because they cannot bind to the host port.

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

1 participant