Added backend and refactored frond-end to support it.

* Removed unecesery home page
* Added PHP Api that provides auth and replaces the json-server for data storage
* Added support for alternate geocode-api
* Added registration  page
This commit is contained in:
2025-05-27 00:42:00 +02:00
parent 25c1b73e32
commit e88269224c
60 changed files with 4438 additions and 8994 deletions

54
Nginx-Example.conf Normal file
View File

@@ -0,0 +1,54 @@
server {
listen 80;
server_name devsrv.tld;
#beginConf
index index.php index.html;
root /<Path to WorldWise hosting folder>;
gzip on;
gzip_proxied any;
gzip_types text/plain text/css text/xml text/javascript application/javascript application/x-javascript image/svg image/svg+xml application/xml image/x-icon;
gzip_comp_level 2;
gzip_disable "msie6";
gzip_buffers 16 8k;
location / {
root /<Path to WorldWise hosting folder>/dist;
try_files $uri $uri/ /index.html;
}
location /api/ {
try_files $uri $uri/ /api/index.php$is_args$query_string;
}
location ~ \.php$ {
fastcgi_pass unix:/var/run/php/php8.4-fpm.sock;
# regex to split $uri to $fastcgi_script_name and $fastcgi_path
fastcgi_split_path_info ^(.+\.php)(/.+)$;
# Check that the PHP script exists before passing it
try_files $fastcgi_script_name =404;
# Bypass the fact that try_files resets $fastcgi_path_info
# see: http://trac.nginx.org/nginx/ticket/321
set $path_info $fastcgi_path_info;
fastcgi_param PATH_INFO $path_info;
fastcgi_index index.php;
include fastcgi.conf;
# Get request file name
fastcgi_param SCRIPT_FILENAME $request_filename;
}
location ~ /\.ht {
deny all;
}
#endConf
}