claabs / epicgames-freegames-node

Automatically login and find available free games the Epic Games Store. Sends you a prepopulated checkout link so you can complete the checkout after logging in. Supports multiple accounts, login sessions, and scheduled runs.
https://hub.docker.com/r/charlocharlie/epicgames-freegames
MIT License
1.39k stars 93 forks source link

[nginx] Cannot GET /custompath #342

Closed laur89 closed 1 year ago

laur89 commented 1 year ago

Haven't modified nginx nor epicgames-freegames config since last time everything worked fine, but now accessing the sent captcha challenge url results in Cannot GET /custompath error.

Relevant part in config.json

"webPortalConfig": {                                                               
  "baseUrl": "https://my.domain.com/custompath",                       
}

nginx site conf:

server {                                                                             
    listen 443 ssl http2;                                                            
    listen [::]:443 ssl http2;                                                       
    server_name my.domain.com;                                                              

    client_max_body_size 0;                                                          

    # note this extra path is for security through obscurity:                    
    location /custompath {                                                                                                                                                                                                                                                                                     
        include /config/nginx/proxy.conf;                                            
        include /config/nginx/resolver.conf;                                         
        proxy_set_header Connection $http_connection;                                
        set $upstream_port 3055;                                                     
        set $upstream_proto http;                                                    
        proxy_pass $upstream_proto://self:$upstream_port$request_uri;                

        access_log      /config/log/nginx/epic.access.log;                           
        error_log       /config/log/nginx/epic.error.log;                            
    }                                                                                

    location / {                                                                     
      return 404;                                                                    
    }                                                                                
}

Any suggestions where to begin debugging this?

claabs commented 1 year ago

You did nothing wrong. I did a recent rewrite of the web portal plugin, and forgot to test basepath support. Just pushed a fix.

Thanks for the report!