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

docker compose fails with docker/compose/pycsw.yml #1002

Closed
1 of 5 tasks
eemilhaa opened this issue Aug 16, 2024 · 0 comments
Closed
1 of 5 tasks

docker compose fails with docker/compose/pycsw.yml #1002

eemilhaa opened this issue Aug 16, 2024 · 0 comments

Comments

@eemilhaa
Copy link
Contributor

Description

docker compose up fails when using the pycsw config in docker/compose/pycsw.yml. This happens with geopython/pycsw:latest. The config file seems to have syntax issues (see logs below). I'll submit a pr to fix this as the issue seems simple enough.

Environment

  • operating system: Fedora Linux 40, (Docker version 27.1.2, Docker Compose version v2.29.1)
  • pycsw version: ghcr.io/geopython/pycsw:latest
  • source/distribution
    • git clone
    • DebianGIS/UbuntuGIS
    • PyPI
    • zip/tar.gz
    • other (please specify): Latest docker image

Steps to Reproduce

cd docker/compose
PYCSW_DOCKER_IMAGE=latest docker compose up

Additional Information

Logs from docker compose up:

[+] Running 2/0
 ✔ Container pycsw  Created                                                                                                              0.0s 
 ✔ Container db     Created                                                                                                              0.0s 
Attaching to db, pycsw
db     | 
db     | PostgreSQL Database directory appears to contain a database; Skipping initialization
db     | 
db     | 2024-08-16 07:43:23.899 UTC [1] LOG:  starting PostgreSQL 12.5 on x86_64-pc-linux-musl, compiled by gcc (Alpine 9.3.0) 9.3.0, 64-bit
db     | 2024-08-16 07:43:23.900 UTC [1] LOG:  listening on IPv4 address "0.0.0.0", port 5432
db     | 2024-08-16 07:43:23.900 UTC [1] LOG:  listening on IPv6 address "::", port 5432
db     | 2024-08-16 07:43:23.908 UTC [1] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
db     | 2024-08-16 07:43:23.937 UTC [22] LOG:  database system was shut down at 2024-08-16 07:05:21 UTC
db     | 2024-08-16 07:43:23.945 UTC [1] LOG:  database system is ready to accept connections
pycsw  | Traceback (most recent call last):
pycsw  |   File "/usr/local/bin/entrypoint.py", line 132, in <module>
pycsw  |     config = yaml_load(fh)
pycsw  |   File "/home/pycsw/pycsw/pycsw/ogc/api/util.py", line 147, in yaml_load
pycsw  |     return yaml.load(fh, Loader=EnvVarLoader)
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/__init__.py", line 81, in load
pycsw  |     return loader.get_single_data()
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/constructor.py", line 49, in get_single_data
pycsw  |     node = self.get_single_node()
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/composer.py", line 36, in get_single_node
pycsw  |     document = self.compose_document()
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/composer.py", line 55, in compose_document
pycsw  |     node = self.compose_node(None, None)
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/composer.py", line 84, in compose_node
pycsw  |     node = self.compose_mapping_node(anchor)
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/composer.py", line 133, in compose_mapping_node
pycsw  |     item_value = self.compose_node(node, item_key)
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/composer.py", line 84, in compose_node
pycsw  |     node = self.compose_mapping_node(anchor)
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/composer.py", line 133, in compose_mapping_node
pycsw  |     item_value = self.compose_node(node, item_key)
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/composer.py", line 84, in compose_node
pycsw  |     node = self.compose_mapping_node(anchor)
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/composer.py", line 127, in compose_mapping_node
pycsw  |     while not self.check_event(MappingEndEvent):
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/parser.py", line 98, in check_event
pycsw  |     self.current_event = self.state()
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/parser.py", line 428, in parse_block_mapping_key
pycsw  |     if self.check_token(KeyToken):
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/scanner.py", line 115, in check_token
pycsw  |     while self.need_more_tokens():
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/scanner.py", line 152, in need_more_tokens
pycsw  |     self.stale_possible_simple_keys()
pycsw  |   File "/usr/local/lib/python3.10/site-packages/yaml/scanner.py", line 291, in stale_possible_simple_keys
pycsw  |     raise ScannerError("while scanning a simple key", key.mark,
pycsw  | yaml.scanner.ScannerError: while scanning a simple key
pycsw  |   in "/etc/pycsw/pycsw.yml", line 109, column 9
pycsw  | could not find expected ':'
pycsw  |   in "/etc/pycsw/pycsw.yml", line 110, column 9
pycsw exited with code 1
eemilhaa added a commit to eemilhaa/pycsw that referenced this issue Aug 16, 2024
- uses the same syntax as docker/pycsw.yml
tomkralidis pushed a commit that referenced this issue Aug 22, 2024
- uses the same syntax as docker/pycsw.yml
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

No branches or pull requests

2 participants