searxng / searxng-docker

The docker-compose files for setting up a SearXNG instance with docker.
GNU Affero General Public License v3.0
1.21k stars 290 forks source link

Need Docker Compose Sanitation #186

Closed techwithjake closed 11 months ago

techwithjake commented 11 months ago

I created my docker compose and in it I had

- INSTANCE_NAME="NAME GOES HERE"

The created settings.yml added the quotation marks as the instance name. Since the settings.yml adds quotation marks as well, there's two pairs and prevents SearxNG from loading.

Relevant log failures

File "/usr/lib/python3.11/site-packages/yaml/parser.py", line 438, in parse_block_mapping_key raise ParserError("while parsing a block mapping", self.marks[-1], yaml.parser.ParserError: while parsing a block mapping in "/etc/searxng/settings.yml", line 3, column 3 expected <block end>, but found '<scalar>' in "/etc/searxng/settings.yml", line 5, column 20

There needs to be some kind of sanitation to prevent the quotation marks being pulled in.

unixfox commented 11 months ago

See here why you don't always need to add quotation marks: https://stackoverflow.com/questions/53082932/yaml-docker-compose-spaces-quotes

return42 commented 11 months ago

just for reference --> For a data format, yaml is extremely complicated. It aims to be a human-friendly format, but in striving for that it introduces so much complexity, that I would argue it achieves the opposite result. Yaml is full of footguns and its friendliness is deceptive.