U
U
Uglevod2022-03-16 16:18:51
linux
Uglevod, 2022-03-16 16:18:51

How to set gunicorn (flask) to run on Alpine Linux?

There is a machine with alpine linux (namely Postmarket OS).
There is a Flask application that will be routed through Nginx.
How to run it?
What I found is the config file for starting the service, there is one directive - the start command - and that's it, there is no working directory for gunicorn...

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Karabanov, 2022-03-16
@karabanov

With supervisor, for example:

[program:example.com]
command=/var/www/example/data/www/example.com/env/bin/gunicorn app.wsgi:application --name example.com --workers 2 --max-requests 1024 --timeout 1200 --preload --bind=unix:/var/www/example/data/tmp/example.com.sock
directory=/var/www/example/data/www/example.com
stdout_logfile=/var/www/example/data/tmp/example.com.stdout.log
stderr_logfile=/var/www/example/data/tmp/example.com.stderr.log
user=example

Choose your own Deploying Gunicorn

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question