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

Add Kubernetes version to user-agent #224

Merged
merged 2 commits into from
Jul 23, 2024
Merged

Conversation

unexge
Copy link
Contributor

@unexge unexge commented Jul 18, 2024

This change bumps image size from 33.21mb to 48.05mb due to addition of Kubernetes client, I was worried about it initially but since we'll need Kubernetes client for other features as well, I think it's acceptable to include it. We can take a look on reducing the image size later if we want to.

A note about escaping, with this change we pass multi user-agents separated by space to mount-s3. systemd quotes all entries passed to ExecStart since v207 (released on Sep 13, 2013, the original support for transient units - the way we start systemd services - added on v205 which released on Jul 3, 2013). I tried quoting arguments before passing to systemd but that causes double escaping on quotes and causes --user-agent-prefix="\"s3-csi-driver/... k8s/...\"" to be passed to mount-s3.

Given that even very old systemds can handle quoting, I expect this change to be safe. I also tested this change on AL2, AL2023, Ubuntu 20.04 and Ubuntu 22.04, and it works fine on these hosts.


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@unexge unexge force-pushed the unexge/k8s-version-in-user-agent branch from 44a453a to e9e2646 Compare July 22, 2024 09:43
@unexge unexge marked this pull request as ready for review July 22, 2024 10:32
@unexge unexge requested a review from muddyfish July 22, 2024 10:51
@unexge unexge force-pushed the unexge/k8s-version-in-user-agent branch from ed4d19c to e9e2646 Compare July 22, 2024 11:40
@unexge unexge force-pushed the unexge/k8s-version-in-user-agent branch from e9e2646 to 749a35f Compare July 23, 2024 09:23
@unexge unexge merged commit 30cae01 into main Jul 23, 2024
8 checks passed
@unexge unexge deleted the unexge/k8s-version-in-user-agent branch July 24, 2024 13:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants