diff --git a/.~lock.document_Install.docx# b/.~lock.document_Install.docx# deleted file mode 100644 index 5918813..0000000 --- a/.~lock.document_Install.docx# +++ /dev/null @@ -1 +0,0 @@ -,PC-KHAM/Kham,PC-KHAM,12.05.2026 18:22,file:///C:/Users/Kham/AppData/Roaming/LibreOffice/4; \ No newline at end of file diff --git a/API/FamilyTreeAPI/Install_Linux.txt b/API/FamilyTreeAPI/Install_Linux.txt index 495babf..9cd9d0e 100644 --- a/API/FamilyTreeAPI/Install_Linux.txt +++ b/API/FamilyTreeAPI/Install_Linux.txt @@ -71,7 +71,11 @@ $ sudo nano /etc/nginx/sites-avaible/default After adding the content, save it. Then let’s enable and start the service: sudo systemctl enable kestrel-app.service sudo systemctl start kestrel-app.service + put familytreeapp.conf + put in /etc/nginx/sites-availalble/familytreeapp.conf + $) sudo ln -s /etc/nginx/sites-available/familytreeapp.conf /etc/nginx/sites-enabled/ + postgresql.conf: Edit postgresql.conf: @@ -104,4 +108,7 @@ $ sudo nano /etc/nginx/sites-avaible/default docker run -p 5432:5432 -e POSTGRES_PASSWORD=123456789 \ -d postgres:9.3.6 \ - -c config_file=/path/to/postgresql.conf \ No newline at end of file + -c config_file=/path/to/postgresql.conf + + + \ No newline at end of file diff --git a/API/FamilyTreeAPI/familytreeapp.conf b/API/FamilyTreeAPI/familytreeapp.conf new file mode 100644 index 0000000..caa6a3c --- /dev/null +++ b/API/FamilyTreeAPI/familytreeapp.conf @@ -0,0 +1,35 @@ +server { + listen 80; + server_name://yourdomain.com # your actaul subdomain + + #root /var/www/familytree/familytreeui; #path to your build files + #index index.html + + location / { + proxy_pass http://127.0.0.1:5000; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection keep-alive; + proxy_set_header Host $host; + proxy_cache_bypass $http_upgrade; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + } + + location /familytreeui/ { + root /var/www/familytree; #path must exist like /var/www/familytree/familytreeui and /var/www/familytree/api folder. + index index.html + try_files $uri $uri/ /index.html; + } + # Optional: Cache static assets for better performance + location ~* \.(?:ico|css|js|gif|jpe?g|png)$ { + expires 30d; + add_header Cache-Control "public"; + } + + error_page 404 /index.html; +} + +# put in /etc/nginx/sites-availalble/familytreeapp.conf +# link to enable +# $) sudo ln -s /etc/nginx/sites-availalble/familytreeapp.conf /etc/nginx/sites-enabled/ \ No newline at end of file