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

wis2box-api breaks too easily #672

Open
david-i-berry opened this issue May 1, 2024 · 3 comments
Open

wis2box-api breaks too easily #672

david-i-berry opened this issue May 1, 2024 · 3 comments
Assignees

Comments

@david-i-berry
Copy link
Member

If a collection or process is misconfigured in the pygeoapi-config.yml the entrypoint.sh script fails and the wis2box-api container fails to start. This is due to https://github.com/wmo-im/wis2box-api/blob/9032a79981098ac368baab3dd9eae1d636677c5c/docker/entrypoint.sh#L61 and the generation of the openapi-config.yml file.

This makes it challenging for users to maintain their collections (and any process plugins), with the container broken on restart if an error is made. This is unnecessary and could be avoided by providing a default openapi-config.yml and updating the openapi-config.yml manually. Instructions are provided as part of pygeoapi: https://docs.pygeoapi.io/en/stable/administration.html#creating-the-openapi-document and this could be part of the system configuration instructions / steps.

Proposed solution:

  1. Include default openapi-config.yml document in the repository / container image.
  2. Remove generation of openapi-config.yml from the entrypoint.sh.
  3. Include instructions on updating the openapi-config.yml file in the wis2box documentation (incl. validation).
  4. Update management container to update the openapi-config.yml when a new collection is added via the metadata editor.
@tomkralidis
Copy link
Collaborator

@david-i-berry do we have an example of a misconfigured collection or process? We can also look into the root cause of such misconfiguration.

Having said this, canning the OpenAPI document is a common pattern for deployments whose configurations only change on a release.

@david-i-berry
Copy link
Member Author

@tomkralidis @maaikelimper bumping this issue again.

By canning do you mean throwing away or having a pre canned version of the file? I was interpreting canning as throwing away.

@tomkralidis
Copy link
Collaborator

Sorry @david-i-berry pre canned (as opposed to binning :) )

@tomkralidis tomkralidis added this to the sprint-015 milestone Jun 24, 2024
@maaikelimper maaikelimper removed this from the sprint-015 milestone Jun 27, 2024
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

3 participants