I want to change the log url displayed in flyte co...
# ask-the-community
r
I want to change the log url displayed in flyte console to where our logs are stored, so I added the entry below to the values. The url does change but it seems like podName is always empty so the url is https://my.papertrailapp.com/systems//events, is there something else I need to do to make the podName variable work? I just looked at the defaults which uses podName too https://docs.flyte.org/en/stable/deployment/cluster_config/flytepropeller_config.html#logs-logs-logconfig
Copy code
task_logs:
    plugins:
      logs:
        kubernetes-enabled: true
        kubernetes-template-uri: <https://my.papertrailapp.com/systems/{{> .podName }}/events
d
Hi @Robin Kahlow, this example seems to work when I test it locally. I'm going to dive through the FlytePlugins code quick to see if somehow the PodName that is used to replace
{{ .podName }}
is somehow empty.
What version of FlytePropeller are you using?
Also, before you updated the template uri was the pod name correctly set in the default config string (as you linked)?
r
flytepropeller: should be whatever the 1.0.0 helm chart uses, is there an easy way to see the version somewhere?
i havent actually checked if the default contained the pod name, ill try removing the key and check again
yea with the default it does contain everything 🤔
d
Interesting, this is implemented as a simple regex replace internally. So if it works for the default configuration, it really should work with your example.
So it looks like the podName is being replaced, but it is just with an empty string. We use the name from the k8s pod. Did you test the default configuration with the same workflow?
And is this just a regular python task or something else?
r
yea just a regular python task
i did test both the default template (ie. no key declared by myself) and my own template for the same workflow
https://github.com/flyteorg/flyte/blob/master/charts/flyte-core/values-eks.yaml#L310 i placed it under here btw, dunno if it makes a difference running flytepropeller standalone (as opposed to the entire flyte-core stack) for the replacement maybe?
d
It shouldn't. If you use other replacement variables do those work? e.x.,
{{ .namespace }}
r
i tried putting the default into my own config, same issue with that (http://localhost:30082/#!/log///pod?namespace=), ie.
Copy code
task_logs:
    plugins:
      logs:
        kubernetes-enabled: true
        kubernetes-template-uri: <http://localhost:30082/#!/log/{{> .namespace }}/{{ .podName }}/pod?namespace={{ .namespace }}
so seems not
this is the command i use to update the values
helm upgrade --atomic --install -n flyte-experimental -f values-eks.yaml --create-namespace flyte flyte/flyte-core
anything wrong with that maybe?
d
Have you tried putting the template uri in quotes? I'm wondering if somewhere the formatting gets broken.
Otherwise @Yuvraj are you aware of any issues with setting logging uri's in the helm charts?
Oh, I bet that helm is replacing those values before setting it. Helm uses the same syntax
{{ .var }}
to set variables - so quoting the string should fix it.
r
i tried quoting it with the same result before, but ill try again when i have some time later
(quoting the entire url right?)
👍 1
helm replacign it was the issue, this worked for me kubernetes-template-uri: https://my.papertrailapp.com/systems/{{`{{ .podName }}`}}/events
that issue should show up for other stuff too then in the example values.yaml, like in the notification
thanks for your help btw 🙂
d
Oh great! We'll have to figure how we can update the helm charts (or configuration) so this isn't a persistent issue.
165 Views