Skip to content

removed quotes to be able to specify multiple additional arguments - #212

Closed
ppaulis wants to merge 2 commits into
joedwards32:mainfrom
osg-lan:main
Closed

removed quotes to be able to specify multiple additional arguments#212
ppaulis wants to merge 2 commits into
joedwards32:mainfrom
osg-lan:main

Conversation

@ppaulis

@ppaulis ppaulis commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

Hi @joedwards32,

I'm trying to add multiple additional arguments like this in my server config:

CS2_ADDITIONAL_ARGS=+sv_deltaticks_enforce 0 +tv_autorecord 1 +tv_relayvoice 0

It works fine with a single argument, but as soon as I add a second one like in the example above, it stops working. My guess is that it's because of the quotes:

"${CS2_ADDITIONAL_ARGS}"

in entry.sh

This PR should fix the problem. Alternatively I could add new env vars for all three properties.

Thanks,
best regards,
Pascal

Signed-off-by: Pascal Paulis <ppaulis@gmail.com>

@joedwards32 joedwards32 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The problem here isn't quoting, it is my simplistic use of eval and string variables.

The correct fix is to covert the input strings into bash arrays.

@ppaulis

ppaulis commented Aug 29, 2026

Copy link
Copy Markdown
Contributor Author

@joedwards32 Thanks :-) I'll get back to you with an updated PR soon.

@ppaulis

ppaulis commented Aug 29, 2026

Copy link
Copy Markdown
Contributor Author

@joedwards32 Tought about it for a few minutes. I could try it with a read -ra ... but there wouldn't be any added value I guess. Because it's coming from a plain string in a docker compose file :

CS2_ADDITIONAL_ARGS=hostname "my Server"

would still be split up into :

  • hostname
  • "my
  • Server"

So, it would probably be easier to add additional env vars for these specific variables?

Signed-off-by: Pascal Paulis <ppaulis@gmail.com>
@ppaulis

ppaulis commented Aug 29, 2026

Copy link
Copy Markdown
Contributor Author

@joedwards32 Created a new PR with two new env vars: #214

In case you prefer separate env vars.

@ppaulis ppaulis closed this Aug 29, 2026
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.

2 participants