Are the scripts running on the same server as the web app?

How often are they running? Can you just query and arbitrary URL and see if
it returns a 200? Why do you need the hash?  Or maybe that other HTTP
method, HEAD?  Then maybe block it at the proxy and just request it
locally.  I guess you have to make sure something doesn't cache it.

I think on fly.io they call it a health check to make sure the container is
up.

- Ian

On Thu, Jan 9, 2025, 7:00 AM Jonathan Vanasco <[email protected]> wrote:

> I have a Pyramid project that has some commandline routines via registered
> script entrypoints (e.g. the /scripts/ directory on the current
> cookiecutters).
>
> A few of these routines need to be run while the pyramid web application
> is running.
>
> I'd like to dummyproof this as much as possible and am trying to think of
> ways to ensure the server is running.
>
> Has anyone done something like this?
>
> First I thought of PIDs/Semaphores, but there could be different
> configuration files used.
>
> My current thought is calculating a hash of the ini file by both the
> commandline and server, and having an endpoint on the server publish it for
> comparison.
>
> Does anyone have a better idea?
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "pylons-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion visit
> https://groups.google.com/d/msgid/pylons-discuss/8f7b3127-ccbe-4533-a988-1c1034f316dbn%40googlegroups.com
> <https://groups.google.com/d/msgid/pylons-discuss/8f7b3127-ccbe-4533-a988-1c1034f316dbn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/pylons-discuss/CADj1%3D671rct86EvRHU%3DcUvJ4-P0yBj71-Gs5fWfgY7nACHrcSw%40mail.gmail.com.

Reply via email to