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

Investigate dropping Supervisor in the CKAN image/container #59

Open
kowh-ai opened this issue May 8, 2024 · 2 comments · May be fixed by #77 or ckan/ckan-docker#164
Open

Investigate dropping Supervisor in the CKAN image/container #59

kowh-ai opened this issue May 8, 2024 · 2 comments · May be fixed by #77 or ckan/ckan-docker#164

Comments

@kowh-ai
Copy link
Contributor

kowh-ai commented May 8, 2024

Investigate if Docker (specifically Docker Compose) can provide built-in mechanisms for managing processes within containers

@kowh-ai
Copy link
Contributor Author

kowh-ai commented May 29, 2024

Will wait until the python 3.10 (bookworm-slim) base image is rolled into master and then will work on the following

Get rid of all references to supervisor in the following files:

  1. Dockerfile.python.3.10
  2. start_ckan.python.3.10.sh

To test: kill processes in the running CKAN container and see if the container restarts. There are the following processes running:

  • /bin/bash /srv/app/start_ckan.sh
  • uwsgi processes (4 processes)

The start_ckan.sh process has an pid of 1 (the root process) so this cannot be killed. however the others can so we kill -9 the uwsgi processes

What about the difference between the following:

  1. Docker.python.3.10

HEALTHCHECK --interval=60s --timeout=5s --retries=5 CMD curl --fail http://localhost:5000/api/3/action/status_show || exit CMD ["/srv/app/start_ckan.sh"]

  1. docker compose yaml file

healthcheck:
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:5000"]
interval: 60s
timeout: 10s
retries: 3s

The docker compose yaml file will override the Dockerfile file - so we can remove these lines from the Dockerfile

As far as healthchecks make sure the datapusher service has the same healthchecks as ckan service

This could be done just for the CKAN 2.11 and CKAN master branches...in that case the Docker file and start script is the normal one

@kowh-ai kowh-ai self-assigned this May 30, 2024
@Markus92
Copy link

Markus92 commented Jul 8, 2024

Hi, has any work already been done on this? We notice in the latest version of the CKAN 2.10.4 docker image (the one from 6 days ago), supervisorctl and crond aren't running anymore and this leads to our harvester not harvesting (we use the supervisor to run the fetch and gather as recommended here: https://github.com/ckan/ckanext-harvest?tab=readme-ov-file#setting-up-the-harvesters-on-a-production-server)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment