# Routing problem with Windows Communication Foundation (WCF) service

**URL:** <https://community.traefik.io/t/routing-problem-with-windows-communication-foundation-wcf-service/13750>\
**Category:** Traefik v2\
**Tags:** docker\
**Created:** [March 14, 2022, 2:49pm UTC](https://community.traefik.io/t/routing-problem-with-windows-communication-foundation-wcf-service/13750 "2022-03-14T14:49:41Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![blasferatu](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/blasferatu/32/5087_2.png) [@blasferatu](https://community.traefik.io/u/blasferatu)\
**Post date:** [March 14, 2022, 2:49pm UTC](https://community.traefik.io/t/routing-problem-with-windows-communication-foundation-wcf-service/13750/1 "2022-03-14T14:49:41Z")

</div>

Hello,

I have containerized a Windows Communication Foundation (WCF) service with Docker and Traefik using _Windows Containers_. I am also using a container with _whoami_ for testing.

However, no matter what I try, I am unable to access the WCF service using a URL.

If I browse to _[http://localhost/whoami](http://localhost/whoami)_, it works.

If I browse to the WCF service using the IP address (e.g. _[http://172.21.181.95/LBWWSDomain.svc](http://172.21.181.95/LBWWSDomain.svc)_), it works.

I thought that browsing to _[http://localhost/LBWWSDomain/LBWWSDomain.svc](http://localhost/LBWWSDomain/LBWWSDomain.svc)_ would work but instead I get a 404 error._[http://localhost/LBWWSDomain.svc](http://localhost/LBWWSDomain.svc)_ does not work either.

**NOTE:** I am running _docker_ in a Windows 10 virtual machine. However, I guess this has no influence on this matter.

I've tried everything I could think of to no avail. I don't understand what I may be doing wrong. Any help would be appreciated.

Thank you.

My _docker-compose.yml_ file:

```dockerfile

version: '3.8'

services:

  traefik:

    # The latest official supported Traefik docker image.

    image: traefik:v2.6.1-windowsservercore-1809

    ports:

      # Exposes port 80 for incomming web requests

      - "80:80"

      # The Web UI port <http://0.0.0.0:8080> (enabled by --api.insecure=true)

      - "8080:8080"

    volumes:

      # So that Traefik can listen to the Docker events.

      - .:C:/etc/traefik

      - type: npipe

        source: \\.\pipe\docker_engine

        target: \\.\pipe\docker_engine

  whoami:

     # A container that exposes an API to show its IP address.

     image: stefanscherer/whoami:windows-amd64-2.0.2

     labels:

       - "traefik.enable=true"

       - "traefik.http.routers.whoami.rule=Path(`/whoami`) || Path(`/whoami/`)"

       - "traefik.http.routers.whoami.entrypoints=web"

     # My WCF service.

  lbwwsdomain:

    image: lbwwsdomain:1.0.0-windows

    labels:

      - "traefik.enable=true"

      - "traefik.http.routers.lbwwsdomain.rule=Path(`/lbwwsdomain`) || Path(`/lbwwsdomain/`)"

      - "traefik.http.routers.lbwwsdomain.entrypoints=web"

```

My _traefik.yml_ file:

```dockerfile

api:

  dashboard: true

  insecure: true

providers:

  docker:

    exposedByDefault: false

    swarmMode: false

    endpoint: npipe:////./pipe/docker_engine

log:

  level: INFO

entryPoints:

  web:

    address: ":80"

```

---

<div class="post-metadata">

**Author:** ![cakiwi](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/cakiwi/32/3205_2.png) [@cakiwi](https://community.traefik.io/u/cakiwi)\
**Post date:** [March 17, 2022, 12:50pm UTC](https://community.traefik.io/t/routing-problem-with-windows-communication-foundation-wcf-service/13750/2 "2022-03-17T12:50:27Z")

</div>

Hi @blasferatu

Path is strict, it will ONLY match `/lbwwsdomain` or `/lbwwsdomain/`

You're most likely going to wan to use a `PathPrefix` rule.

---

<div class="post-metadata">

**Author:** ![blasferatu](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/blasferatu/32/5087_2.png) [@blasferatu](https://community.traefik.io/u/blasferatu)\
**Post date:** [March 19, 2022, 2:15pm UTC](https://community.traefik.io/t/routing-problem-with-windows-communication-foundation-wcf-service/13750/3 "2022-03-19T14:15:35Z")

</div>

Hi @cakiwi,

Thank you for your reply.

I had already tried what you suggest to no avail, i.e. using `traefik.http.routers.lbwwsdomain.rule=PathPrefix(`/lbwwsdomain`)`.

After several days and starting to doubt my sanity, I think I have found the problem.

If I type e.g. **[http://localhost/lbwwsdomain.svc](http://localhost/lbwwsdomain.svc)** all in **lower case** , it works. If I type the URL with **mixed case** (e.g. **[http://localhost/LBWWSDomain.svc](http://localhost/LBWWSDomain.svc)**), it does not work, I get a 404 error. I thought Traefik would treat these URLs as being the same. I didn't find any information about this in the documentation.

Now I have my services working using `PathPrefix` and lower case URLs.

I found information about this here: [Case sensitive domain names breaks routing · Issue #562 · traefik/traefik · GitHub](https://github.com/traefik/traefik/issues/562)

It seems it has been fixed: [Fix case sensitive host by emilevauge · Pull Request #733 · traefik/traefik · GitHub](https://github.com/traefik/traefik/pull/733)

Am I missing something?

Thank you.

![1](https://us1.discourse-cdn.com/flex020/uploads/containo/original/2X/7/747a89242c951444fa2d3904d394c13cdae2176c.png)

 ![2](https://us1.discourse-cdn.com/flex020/uploads/containo/original/2X/1/11740dd0120c0f55ce9d2ca0f5520b36d24170e8.png)

---

<div class="post-metadata">

**Author:** ![cakiwi](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/cakiwi/32/3205_2.png) [@cakiwi](https://community.traefik.io/u/cakiwi)\
**Post date:** [March 20, 2022, 2:03am UTC](https://community.traefik.io/t/routing-problem-with-windows-communication-foundation-wcf-service/13750/4 "2022-03-20T02:03:31Z")

</div>

> URLs in general are case-sensitive (with the exception of machine names). There may be URLs, or parts of URLs, where case doesn't matter, but identifying these may not be easy. Users should always consider that URLs are case-sensitive.

[https://www.w3.org/TR/WD-html40-970708/htmlweb.html#htmlhttp](https://www.w3.org/TR/WD-html40-970708/htmlweb.html#htmlhttp)

Will be buried in an RFC somewhere.

---

<div class="post-metadata">

**Author:** ![blasferatu](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/blasferatu/32/5087_2.png) [@blasferatu](https://community.traefik.io/u/blasferatu)\
**Post date:** [March 20, 2022, 11:18am UTC](https://community.traefik.io/t/routing-problem-with-windows-communication-foundation-wcf-service/13750/5 "2022-03-20T11:18:39Z")

</div>

Thank you for your help, @cakiwi. I was not aware of this.

I am used to working with Microsoft's Internet Information Services where the casing of any part of the URL is irrelevant.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex020/uploads/containo/original/2X/b/bd81ebdb578656e76e56ff3cc3eed021d3ba132d.png) [@system](https://community.traefik.io/u/system)\
**Post date:** [March 23, 2022, 11:19am UTC](https://community.traefik.io/t/routing-problem-with-windows-communication-foundation-wcf-service/13750/6 "2022-03-23T11:19:28Z")

</div>

Closed on March 23, 2022, 11:19am UTC

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.
