To make my own IPFS gateway.
I setup up IPFS (go-ipfs) and init it.
Then config nginx, proxy https(443) request to ipfs port 8080.
My page (“https://ipfs.mydomain.com/webui”, .e.g) has something wrong.
Html/JS content is ok,but api request is bad,because the url is http and port 443。 such as “http://ipfs.mydomain.com:443/api/v0/id?stream-channels=true”
What happen?
My Nginx Config:
server {
server_name ipfs.mydomain.com;
listen 443 ssl;
ssl on;
ssl_certificate /root/.ipfs/https_full_chain.pem;
ssl_certificate_key /root/.ipfs/https_private.key;
ssl_session_timeout 5m;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
charset UTF-8;
location / {
proxy_pass http://127.0.0.1:8080;
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}