A valid label must be an empty string or consist of alphanumeric characters

I am trying to deploy my application but I am getting the following yaml error for the traefik label I am adding so that Traefik will detect the application.

$ kubectl apply -f example-app.yml

The ReplicationController “example-app” is invalid:

* metadata.labels: Invalid value: "Host(\ mydomain.com \ )":

a valid label must be an empty string or consist of alphanumeric characters, '-', '' or '.', and must start and end with an alphanumeric character (e.g. 'MyValue', or 'my_value', or '12345', regex used for validation is '(([A-Za-z0-9][-A-Za-z0-9.]*)?[A-Za-z0-9])?')\ ``

My example-app.yml:

apiVersion: v1

kind: ReplicationController

metadata:

namespace: example

name: example-app

labels:

example-component: "example-app"

traefik.enable: "true"

traefik.http.routers.example-app.rule: "Host(\ mydomain.com)"

traefik.http.routers.example-app.entrypoints: "web"

I also tried:

- "example-component=example-app"

- "traefik.http.routers.example-app.rule=Host( mydomain.com )"

- "traefik.http.routers.example-app.entrypoints=web"

- "traefik.enable=true"

but get:

invalid type for io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta.labels: got “array”, expected “map”];