Re: Can someone explain me why "curl: (7) Failed to connect to 127.0.0.1 port 2000: Connection refused" ?

2020-05-13 Thread MarcoI
I solved it . It was mix of small little problems that together hindered the correct answer: - changed in golang webserver HOST = 127.0.0.1 - capitalized the first letter of each element of the Puser struct in order to make it visible to json decoder - used correctly the curl command: curl -d'{"fi

Can someone explain me why "curl: (7) Failed to connect to 127.0.0.1 port 2000: Connection refused" ?

2020-05-13 Thread MarcoI
Hi!, I do not understand why it says "curl: (7) Failed to connect to 127.0.0.1 port 2000: Connection refused" : curl -X POST -F 'first_name=pinco' -F 'last_name=pallo' -F 'company_name=Company' -F 'email=pinco.pa...@company.com' -F 'tel=1' 127.0.0.1:2000/puser/add curl: (7) Failed to conne

Re: Static files

2020-05-11 Thread MarcoI
Following the indications here: https://docs.nginx.com/nginx/admin-guide/web-server/serving-static-content/ I modified the lines in /etc/nginx/conf.d/default.conf as follows: server { root /home/marco/webMatters/vueMatters/GraspGlobalChances/src/components/auth/weights; location / {

Static files

2020-05-11 Thread MarcoI
I'm trying to figure out how to load static files . I added to /etc/nginx/conf.d/default.conf the following lines: server { location / { root /home/marco/webMatters/vueMatters/ggc/src/components/auth/weights; } } But I'm still getting this error: Uncaught (in promise) SyntaxError:

Re: POST result: 404

2020-05-01 Thread MarcoI
I tried to curl POST the entire form: (base) marco@pc01:/var/log/nginx$ curl -X POST -F 'first_name=pinco' -F 'last_name=pallo' -F 'company_name=Company' -F 'email=pinco.pa...@company.com' -F 'tel=1' http://127.0.0.1:8080/puser/add Error Cannot POST /puser/add Posted at Nginx For

Re: POST result: 404

2020-05-01 Thread MarcoI
It doesn't produce a "404" but it is saying "Cannot POST" ...: curl -X POST http://127.0.0.1:8080/puser/add Error Cannot POST /puser/add These are the corresponding lines in /var/log/nginx : 128.14.134.170 - - [01/May/2020:10:04:03 +0200] "GET / HTTP/1.1" 502 584 "-" "Mozilla/5.0 (Win

Re: POST result: 404

2020-04-30 Thread MarcoI
Hi Thomas, thank you for your kind help. I'm not sure, due to my lack of knowledge, how I can check if the path from port 443 to port 8080 works in my app when accessed directly on my system. (base) marco@pc01:~$ sudo netstat -plnt Active Internet connections (only servers) Proto Recv-Q Send-Q Lo

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-04-30 Thread MarcoI
Hi Francis, I remember you have deep expertise with nginx configuration. I posted in the mailing list a question about how to configure nginx in order to use also golang webserver. Would you be so kind in having a look at it? https://forum.nginx.org/read.php?2,287914 Thank you very much. Looking

POST result: 404

2020-04-30 Thread MarcoI
This is the nginx configuration in Ubuntu 18.04 : server { listen 443 ssl http2 default_server; server_name ggc.world; ssl_certificate /etc/letsencrypt/live/ggc.world/fullchain.pem; # managed by Certbot ssl_certificate_key /etc/letsencrypt/live/ggc.world/privke

Re: This site can’t be reached: what aspects, elements, configurations, do I have to check and verify?

2020-02-17 Thread MarcoI
Big Update:SOLVED (but still do not know why)... I fixed the PC's IP Address, and everything went fine But I do not actually understand why everything went fine, if, before the problem with the software installation, the local ip address was dynamic and it was already working fine. Posted at

This site can’t be reached: what aspects, elements, configurations, do I have to check and verify?

2020-02-17 Thread MarcoI
Hi all, just the day after getting everything fine: https://forum.nginx.org/read.php?2,286991,287001#msg-287001, during installation of another software in the PC I got problems with grub system in Ubuntu 18.04.4 Desktop, which I resolved copying, from an installation iso image, the /bin/bash folde

Re: net::ERR_SSL_PROTOCOL_ERROR

2020-02-12 Thread MarcoI
Solved the problem thanks to Francis Daly who pointed me to the right direction: https://forum.vuejs.org/t/vue-with-nginx/26843/3 // vue.config.js module.exports = { // options... publicPath: '', devServer: { host: '0.0.0.0', port: 8080, public:

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-02-12 Thread MarcoI
Thank you very much Francis!!! Your indications solved this problem: with vue.config.js : // vue.config.js module.exports = { // options... publicPath: '', devServer: { host: '0.0.0.0', port: 8080, public: 'ggc.world' }, } now it works fine: https://drive.google.com/open?id=1

Re: RE: net::ERR_SSL_PROTOCOL_ERROR

2020-02-12 Thread MarcoI
Hi Reinis, setting in /etc/nginx/conf.d/default.conf proxy_set_header Host $host in the location / as follows: server { listen 443 ssl http2 default_server; server_name ggc.world; ssl_certificate /etc/letsencrypt/live/ggc.world/fullchain.pem; # managed by Certbot

Re: net::ERR_SSL_PROTOCOL_ERROR

2020-02-11 Thread MarcoI
Hi!, I do not understand what should I modify. If I should use ggc,world when connecting with the browser, this is what I already do: https://drive.google.com/open?id=10MYySDKhPx9L-QucqzxN5NTratJEOJZR If instead I should put ggc.world instead of local (127.0.0.1) in /etc/nginx/conf.d/default.con

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-02-11 Thread MarcoI
Hi Francis, I "solved" this problem installing the Desktop version of Ubuntu 18.04 as I described here: https://askubuntu.com/questions/1207812/webapp-fails-with-neterr-connection-refused-with-ubuntu-18-04-4-server-edition Now I've got a different, but may be, similar, problem, which I described

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-02-11 Thread MarcoI
Hi Francis, I "solved" this problem installing the Desktop version of Ubuntu 18.04, as I described here: https://askubuntu.com/questions/1207812/webapp-fails-with-neterr-connection-refused-with-ubuntu-18-04-4-server-edition Now I have a different, but may be, similar, problem, which I described i

net::ERR_SSL_PROTOCOL_ERROR

2020-02-11 Thread MarcoI
Today I issued and installed SSL certificates for my website. This is the rating assigned by https://www.ssllabs.com/ssltest/analyze.html : https://drive.google.com/open?id=1-Fb4h1dmdJ8kN68JxKROWwu4ezGmjm6R This is the result of https://check-your-website.server-daten.de/ which indicates "only

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-02-01 Thread MarcoI
This is the "view source" of the html page: testproject We're sorry but testproject doesn't work properly without JavaScript enabled. Please enable it to continue.

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-31 Thread MarcoI
This is the output of the "Network" tab : https://drive.google.com/open?id=1QJMe8FEBrEuWacHWeJ_TQegMkF0v68AY " Either a http redirect response header, or some response body content, invites the browser to try to access localhost" : as far as I see and understand, the requested URL, or the URL to wh

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-31 Thread MarcoI
Sorry I have to complete the last answer: >From the laptop: (base) marco@marco-U36SG:~$ curl -vk https://ggc.world/sockjs-node/info?t=1580397983088 * Trying 2.36.58.214:443... * TCP_NODELAY set * Connected to ggc.world (2.36.58.214) port 443 (#0) * ALPN, offering http/1.1 * successfully set cer

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-31 Thread MarcoI
>From within the PC-Server: (base) marco@pc:~/vueMatters/testproject$ curl -vk https://localhost/sockjs-node/info?t=1580397983088 * Trying ::1... * TCP_NODELAY set * connect to ::1 port 443 failed: Connection refused * Trying 127.0.0.1... * TCP_NODELAY set * Connected to localhost (127.0.0.1)

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-31 Thread MarcoI
I add more information and a question: >From within the PC-Server: (base) marco@pc:~$ curl -Iki https://localhost/sockjs-node/info?t=1580397983088 HTTP/2 405 server: nginx/1.14.0 (Ubuntu) date: Fri, 31 Jan 2020 08:19:02 GMT allow: OPTIONS, GET >From the laptop: (base) m

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-30 Thread MarcoI
With this /etc/nginx/conf.d/default.conf : server { listen 443 ssl http2 default_server; server_name ggc.world; ssl_certificate /etc/ssl/certs/chained.pem; ssl_certificate_key /etc/ssl/private/domain.key; ssl_session_timeout 5m; ssl_protocols

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-30 Thread MarcoI
Sorry for my ignorance... how to practically modify the /etc/nginx/conf.d/default.conf ? Posted at Nginx Forum: https://forum.nginx.org/read.php?2,286850,286864#msg-286864 ___ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-30 Thread MarcoI
Hi Francis, thanks for helping. curl on PC-Server (Ubuntu 18.04.03 Server Edition): (base) marco@pc:~/vueMatters/testproject$ curl -Iki http://localhost:8080/ HTTP/1.1 200 OK X-Powered-By: Express Accept-Ranges: bytes Content-Type: text/html; charset=UTF-8 Content-Length: 774 ETag: W/"306-TZR

Re: net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-29 Thread MarcoI
Add-on to the previous email: using firefox as web browser, I get this error message: https://drive.google.com/open?id=1l6USIHrbHl6kBcQtormXplOgx0J653ko "Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://localhost/sockjs-node/info?t=1580304400

net::ERR_CONNECTION_REFUSED . How to correctly configure Nginx with Socket.io?

2020-01-29 Thread MarcoI
I created a brand new tiny webapp with vue cli, so without adding anything, apart from what the empty vue-cli scaffolding brings: (base) marco@pc:~/vueMatters/testproject$ npm run serve > testproject@0.1.0 serve /home/marco/vueMatters/testproject > vue-cli-service serve INFO Sta