You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

34 lines
583 B

3 years ago
  1. ## Requirements
  2. pip:
  3. * wheel
  4. * gunicorn
  5. * flask
  6. ## Unit File
  7. ```shell
  8. [Unit]
  9. Description=Gunicorn instance for primemeat
  10. After=network.target
  11. [Service]
  12. User=maintenance
  13. Group=www-data
  14. WorkingDirectory=/path/to/project
  15. Environment="PATH=/path/to/project/bin"
  16. #remove --reload when site is ready
  17. #reload restarts workers when code changes
  18. ExecStart=/path/to/project/bin/gunicorn --reload --workers 3 --bind 0.0.0.0:8900 wsgi:app
  19. [Install]
  20. WantedBy=multi-user.target
  21. ```
  22. ## Caddy
  23. ```shell
  24. primemeat.some.domain.org {
  25. root * /path/to/project
  26. reverse_proxy localhost:8900
  27. }
  28. ```