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

Ingress error with ExternalName Service #317

Closed
jam13 opened this issue Dec 13, 2018 · 4 comments
Closed

Ingress error with ExternalName Service #317

jam13 opened this issue Dec 13, 2018 · 4 comments
Assignees
Labels
area/resource-management Issues related to Kubernetes resource provisioning, management, await logic, and semantics generally kind/bug Some behavior is incorrect or out of spec p1 A bug severe enough to be the next item assigned to an engineer
Milestone

Comments

@jam13
Copy link

jam13 commented Dec 13, 2018

I am creating an Service of type ExternalName along with an Ingress that uses it like this:

const service = new k8s.core.v1.Service("foo", {
    metadata: {
        name: "foo",
        namespace: "default",
    },
    spec: {
        type: "ExternalName",
        externalName: "foo.s3-website-eu-west-1.amazonaws.com",
        ports: [
            {
                port: 80,
            },
        ],
    },
}, {provider: k8sProvider});

const ingress = new k8s.extensions.v1beta1.Ingress("foo", {
    metadata: {
        annotations: {
            "kubernetes.io/ingress.class": "traefik",
            "traefik.frontend.passHostHeader": "false",
            "traefik.frontend.priority": "1"
        },
        name: "foo",
        namespace: "default",
    },
    spec: {
        rules: [
            {
                host: "*.example.com",
                http: {
                    paths: [
                        {
                            backend: {
                                serviceName: "foo",
                                servicePort: 80,
                            },
                            path: "/",
                        },
                    ],
                },
            },
        ],
    },
}, {provider: k8sProvider});

Both are created correctly, and it works as expected (all incoming traffic to *.example.com is proxied to an S3 bucket), however Pulumi hangs with this error:

error: No matching service found for ingress rule: "/"

It appears that it's not considering Services of this type as a valid target.

@lukehoban lukehoban added this to the 0.20 milestone Dec 13, 2018
@lblackstone
Copy link
Member

Yes, this appears to be an oversight in the provider code. I'll get this fixed shortly.

@hausdorff hausdorff added kind/bug Some behavior is incorrect or out of spec area/resource-management Issues related to Kubernetes resource provisioning, management, await logic, and semantics generally priority/P1 labels Dec 18, 2018
@hausdorff hausdorff assigned hausdorff and unassigned lblackstone Dec 18, 2018
@hausdorff
Copy link
Contributor

Taking over while Levi is out, this should be pretty easy to get merged in over the next few days.

@dragosbulugean
Copy link

dragosbulugean commented Dec 24, 2018

If it helps, same thing happens when fronting for basic k8s service with
"kubernetes.io/ingress.class": "nginx"

@hausdorff
Copy link
Contributor

@dragosbulugean Sorry, I'm not sure I understand. This issue should arise regardless of the annotation, as long as the Ingress points at a v1/Service whose type is ExternalName, right? Is there something special about the annotation that you believe is causing us to handle that case incorrectly?

If so, please open another issue -- this one is about to close.

@infin8x infin8x added the p1 A bug severe enough to be the next item assigned to an engineer label Jul 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/resource-management Issues related to Kubernetes resource provisioning, management, await logic, and semantics generally kind/bug Some behavior is incorrect or out of spec p1 A bug severe enough to be the next item assigned to an engineer
Projects
None yet
Development

No branches or pull requests

6 participants