Realtime App
-
Realtime Node/Express/Redis app.
Gebruiker op server: realtime
pad installatie: /home/realtime/domains/live.thefreighthero.nl/tfhapp -
Service op server:
/etc/systemd/system/realtime.serviceRestart Redis:
systemctl restart redis.servicesystemctl [start|stop|restart] realtime
# This is a .service file for systemd(8) # # If you are using systemd as a system daemon manager, you may use this file # (with your own local modifications) as a reference. # # This file may be copied to /etc/systemd/system/ and modified with your own # local changes, such as the user to run the daemon as, and where the daemon # is located # To reload systemd daemon after changes to this file: # systemctl --system daemon-reload [Unit] Description=Realtime app The Freight Hero. After=system.slice multi-user.target [Service] Type=simple User=realtime StandardOutput=syslog StandardError=syslog SyslogIdentifier=realtimetfh ExecStart=/home/realtime/start_production.sh Restart=on-failure [Install] WantedBy=multi-user.target -
Custom httpd config directadmin, based on nodebb recommendations.
important added
ProxyPass /.well-known !to prevent the Let's Encrypt SSL certificate check to be proxied#https://docs.nodebb.org/configuring/proxies/apache/ |*if SSL_TEMPLATE="0"| # Rewrite any http traffic to the main url https site <IfModule mod_rewrite.c> RewriteEngine On RewriteRule ^[^\/]*\/(.*) https://live.thefreighthero.nl/$1 [R=301,L] </IfModule> |*else| Protocols h2 http/1.1 # Basic security headers Header always set X-Content-Type-Options "nosniff" Header always set X-Xss-Protection "1; mode=block" # NodeBB header RequestHeader set X-Forwarded-Proto "https" # Static file cache <FilesMatch "\.(ico|jpg|jpeg|png|gif|js|css)$"> <IfModule mod_expires.c> ExpiresActive on ExpiresDefault "access plus 14 days" Header set Cache-Control "public" </IfModule> </FilesMatch> SSLProxyEngine On ProxyRequests off <Proxy *> Order deny,allow Allow from all </Proxy> # Websocket passthrough RewriteEngine On RewriteCond %{REQUEST_URI} ^/socket.io [NC] RewriteCond %{QUERY_STRING} transport=websocket [NC] RewriteRule /(.*) ws://127.0.0.1:5678/$1 [P,L] # prevent proxy for cert check let's encrypt ProxyPass /.well-known ! ProxyPass / http://127.0.0.1:5678/ ProxyPassReverse / http://127.0.0.1:5678/ |*endif| -
Realtime app haalt data uit actieve zendingen.
De verzendingen, bedrijven en telefoonnummers worden opgehaald d.m.v. een query op actieve verzendingen. Dus mis je een telefoonnummer. Dit kan zijn dat het van een leverancier is waarvan we de telefoonnummer sniet hebben opgeslagen. -
N nikitaskliarov moved this topic from TFH Tech on