diff --git a/conf/.env b/conf/.env new file mode 100644 index 0000000..eba5e77 --- /dev/null +++ b/conf/.env @@ -0,0 +1,8 @@ +WT_JWT_ENCRYPTION_KEY= +WT_BIND="[::]:__PORT__" +WT_LOGGING="true" +WT_DEBUG="false" +WT_DATABASE_DRIVER="sqlite" +WT_DSN="./database.db" +WT_REGISTRATION_DISABLED="false" +WT_SOCIALS_DISABLED="false" \ No newline at end of file diff --git a/conf/extra_php-fpm.conf b/conf/extra_php-fpm.conf deleted file mode 100644 index 700c37c..0000000 --- a/conf/extra_php-fpm.conf +++ /dev/null @@ -1,4 +0,0 @@ -; Additional php.ini defines, specific to this pool of workers. - -php_admin_value[upload_max_filesize] = 50M -php_admin_value[post_max_size] = 50M diff --git a/conf/nginx.conf b/conf/nginx.conf index 1e6eee0..2c101f2 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -1,28 +1,17 @@ #sub_path_only rewrite ^__PATH__$ __PATH__/ permanent; location __PATH__/ { - # Path to source - alias __INSTALL_DIR__/; + # Set max upload size + client_max_body_size 20m; -### Example PHP configuration (remove it if not used) - index index.php; + proxy_pass http://127.0.0.1:__PORT__/; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header Host $host; + proxy_redirect default; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-Host $server_name; + proxy_set_header X-Forwarded-Proto $scheme; - # Common parameter to increase upload size limit in conjunction with dedicated php-fpm file - # client_max_body_size 50M; - - try_files $uri $uri/ index.php; - location ~ [^/]\.php(/|$) { - fastcgi_split_path_info ^(.+?\.php)(/.*)$; - fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm-__NAME__.sock; - - fastcgi_index index.php; - include fastcgi_params; - fastcgi_param REMOTE_USER $remote_user; - fastcgi_param PATH_INFO $fastcgi_path_info; - fastcgi_param SCRIPT_FILENAME $request_filename; - } -### End of PHP configuration part - - # Include SSOWAT user panel. + # Include SSOWAT user panel. include conf.d/yunohost_panel.conf.inc; -} +} \ No newline at end of file diff --git a/conf/systemd.service b/conf/systemd.service index 97d2900..413d0b9 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -1,5 +1,5 @@ [Unit] -Description=Small description of the service +Description=workout-tracker service After=network.target [Service] @@ -7,7 +7,7 @@ Type=simple User=__APP__ Group=__APP__ WorkingDirectory=__INSTALL_DIR__/ -ExecStart=__INSTALL_DIR__/script +ExecStart=__INSTALL_DIR__/workout-tracker StandardOutput=append:/var/log/__APP__/__APP__.log StandardError=inherit