-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Possible regex bug in Quadlet #25339
Comments
Thanks for reporting this. I was able to reproduce this issue and the fact that if I remove the |
I found the following:
In the meanwhile the solution is to escape the
Set:
Let me know if this solves your issue. |
@giuseppe @Luap99 @alexlarsson WDYT? |
How does a regular systemd unit parse that string? My assumption is the parsing should behave the same between quadlet and systemd. |
You're right. I've tried the following service unit file that defines a variable and echos its value. I then tested a value with Without escaping:
I got the following error in the journal:
But with escaping:
I got:
So, to follow systemd's behavior, the code should not change and escaping in the Quadlet file is required. Having said that, currently, the behavior is a silent disregard of the error. Should Quadlet:
|
@ygalblum Hi thanks for that! I've tested it and it did work. So like the discussion, IMO it might be better to show a warning when Quadlet ignores the syntax, which is Systemd's behavior, and make debugging much easier. |
Issue Description
I'm running a Traefik container via Quadlet, there is a line in this
traefik.container
is like this:Label=traefik.http.middlewares.redirect.redirectregex.regex=^https://(.*)/.well-known/(webfinger|nodeinfo|host-meta)(\?.*)?$
However, the
.service
file generated does not contain this line, after some tweaking, found out it's related to\?
, it's perfectly fine if without it. I'm guessing it might be about the regex processing part of Quadlet?Steps to reproduce the issue
traefik.container
in~/.config/containers/systemd/
Label=traefik.http.middlewares.redirect.redirectregex.regex=^https://(.*)/.well-known/(webfinger|nodeinfo|host-meta)(\?.*)?$
systemctl --user daemon-reload
systemctl --user cat traefik.service
and that line is not included in the.service
fileDescribe the results you received
I've messed around with the regex, found out it's related to
\?
in the line, it can be included fine if without it. I'm guessing it might be about the regex processing part of Quadlet? I also tried wrap the line with""
but didn't work.Describe the results you expected
Label=traefik.http.middlewares.redirect.redirectregex.regex=^https://(.*)/.well-known/(webfinger|nodeinfo|host-meta)(\?.*)?$
should be included.podman info output
Podman in a container
No
Privileged Or Rootless
Rootless
Upstream Latest Release
No
Additional environment details
No response
Additional information
No response
The text was updated successfully, but these errors were encountered: