diff --git a/hosts_app.service b/hosts_app.service index 45a525a..dee00c7 100644 --- a/hosts_app.service +++ b/hosts_app.service @@ -1,19 +1,12 @@ [Unit] -Description=Hosts Application +Description=.etc.hosts Manager Waitress Service After=network.target [Service] -#User=www-data # Zmień na odpowiedniego użytkownika -#Group=www-data WorkingDirectory=/opt/hosts_app -Environment="PATH=/opt/hosts_app/venv/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" -Environment="FLASK_APP=app.py" -Environment="FLASK_ENV=production" - -ExecStart=/opt/hosts_app/venv/bin/gunicorn -c /opt/hosts_app/gunicorn_config.py app:app - +ExecStart=/opt/hosts_app/venv/bin/python3 /opt/hosts_app/run_waitress.py Restart=always -RestartSec=5 +Environment=PYTHONUNBUFFERED=1 [Install] WantedBy=multi-user.target diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..cba6f7e --- /dev/null +++ b/requirements.txt @@ -0,0 +1,7 @@ +Flask +Werkzeug +Flask-SQLAlchemy +paramiko +apscheduler +gunicorn +waitress \ No newline at end of file